|
|
@ -1,6 +1,6 @@
|
|
|
|
<template>
|
|
|
|
<template>
|
|
|
|
<div class="app-container">
|
|
|
|
<div class="app-container">
|
|
|
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="108px">
|
|
|
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="98px">
|
|
|
|
<el-form-item label="设备编码" prop="equipmentCode">
|
|
|
|
<el-form-item label="设备编码" prop="equipmentCode">
|
|
|
|
<el-input
|
|
|
|
<el-input
|
|
|
|
v-model="queryParams.equipmentCode"
|
|
|
|
v-model="queryParams.equipmentCode"
|
|
|
@ -17,14 +17,17 @@
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
<el-form-item label="设备类型编码" prop="equipmentTypeCode">
|
|
|
|
<el-form-item label="设备类型" prop="equipmentTypeCode">
|
|
|
|
<el-input
|
|
|
|
<el-select
|
|
|
|
v-model="queryParams.equipmentTypeCode"
|
|
|
|
v-model="queryParams.equipmentTypeCode"
|
|
|
|
placeholder="请输入设备类型编码"
|
|
|
|
placeholder="请选择设备类型"
|
|
|
|
clearable
|
|
|
|
@change="$forceUpdate()"
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
clearable
|
|
|
|
/>
|
|
|
|
style="width:205px"
|
|
|
|
</el-form-item>
|
|
|
|
@keyup.enter.native="handleQuery">
|
|
|
|
|
|
|
|
<el-option v-for="item in equipmentTypeOption" :key="item.equipmentTypeCode" :label="item.equipmentTypeName" :value="item.equipmentTypeCode"></el-option>
|
|
|
|
|
|
|
|
</el-select>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
<el-form-item>
|
|
|
|
<el-form-item>
|
|
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
|
@ -97,8 +100,8 @@
|
|
|
|
>{{scope.row.equipmentCode}}</el-button>
|
|
|
|
>{{scope.row.equipmentCode}}</el-button>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column label="设备名称" align="center" prop="equipmentName" />
|
|
|
|
<el-table-column label="设备名称" align="center" prop="equipmentName" width="120"/>
|
|
|
|
<el-table-column label="规格型号" align="center" prop="equipmentSpec" />
|
|
|
|
<el-table-column label="规格型号" align="center" prop="equipmentSpec" width="120"/>
|
|
|
|
<el-table-column label="设备类型编码" align="center" prop="equipmentTypeCode" width="120" />
|
|
|
|
<el-table-column label="设备类型编码" align="center" prop="equipmentTypeCode" width="120" />
|
|
|
|
<el-table-column label="设备类型名称" align="center" prop="equipmentTypeName" width="120"/>
|
|
|
|
<el-table-column label="设备类型名称" align="center" prop="equipmentTypeName" width="120"/>
|
|
|
|
<el-table-column label="所属工作中心编码" align="center" prop="workshopCode" width="150"/>
|
|
|
|
<el-table-column label="所属工作中心编码" align="center" prop="workshopCode" width="150"/>
|
|
|
@ -391,15 +394,16 @@
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
<script>
|
|
|
|
import { listEquipment, getEquipment, delEquipment, addEquipment, updateEquipment} from "@/api/wms/equipment";
|
|
|
|
import { listEquipment, getEquipment, delEquipment, addEquipment, updateEquipment,getEquipmentTypeList} from "@/api/wms/equipment";
|
|
|
|
import { getWorkCenterList,listFactory} from "@/api/wms/factory";
|
|
|
|
import { getWorkCenterList,listFactory} from "@/api/wms/factory";
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
name: "Equipment",
|
|
|
|
name: "Equipment",
|
|
|
|
dicts: ['sys_normal_disable', 'equ_type'],
|
|
|
|
dicts: ['sys_normal_disable', 'equ_type'],
|
|
|
|
data() {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
workCenter:[],
|
|
|
|
equipmentTypeOption:[],
|
|
|
|
options1: [],
|
|
|
|
workCenter:[],
|
|
|
|
|
|
|
|
options1: [],
|
|
|
|
value: '',
|
|
|
|
value: '',
|
|
|
|
// 遮罩层
|
|
|
|
// 遮罩层
|
|
|
|
loading: true,
|
|
|
|
loading: true,
|
|
|
@ -466,8 +470,17 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
created() {
|
|
|
|
created() {
|
|
|
|
this.getList();
|
|
|
|
this.getList();
|
|
|
|
|
|
|
|
this.getEquipmentType();
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
|
|
|
|
/** 查询设备分类 */
|
|
|
|
|
|
|
|
getEquipmentType() {
|
|
|
|
|
|
|
|
getEquipmentTypeList().then(response => {
|
|
|
|
|
|
|
|
console.log(response.rows);
|
|
|
|
|
|
|
|
this.equipmentTypeOption = response.rows;
|
|
|
|
|
|
|
|
console.log(this.treeData1);
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
},
|
|
|
|
selectWorkCenter(){
|
|
|
|
selectWorkCenter(){
|
|
|
|
this.form.workshopCode = this.form.workCenter;
|
|
|
|
this.form.workshopCode = this.form.workCenter;
|
|
|
|
},
|
|
|
|
},
|
|
|
|