|
@@ -619,6 +619,27 @@
|
|
|
</template>
|
|
</template>
|
|
|
</ele-pro-table>
|
|
</ele-pro-table>
|
|
|
</el-tab-pane>
|
|
</el-tab-pane>
|
|
|
|
|
+
|
|
|
|
|
+ <el-tab-pane label="关键设备" name="关键设备">
|
|
|
|
|
+ <ele-pro-table
|
|
|
|
|
+ ref="deviceTabRef"
|
|
|
|
|
+ :columns="standardCol"
|
|
|
|
|
+ :datasource="datasource"
|
|
|
|
|
+ :need-page="false"
|
|
|
|
|
+ :immediate="true"
|
|
|
|
|
+ >
|
|
|
|
|
+ <!-- 表头工具栏 -->
|
|
|
|
|
+ <template v-if="!isView" v-slot:toolbar>
|
|
|
|
|
+ <el-button type="primary" @click="add">添加</el-button>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template v-slot:action="{ row, $index }">
|
|
|
|
|
+ <el-link type="danger" @click="handleDel(row, $index)"
|
|
|
|
|
+ >删除</el-link
|
|
|
|
|
+ >
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </ele-pro-table>
|
|
|
|
|
+ </el-tab-pane>
|
|
|
|
|
+
|
|
|
<el-tab-pane label="制造资源" name="制造资源">
|
|
<el-tab-pane label="制造资源" name="制造资源">
|
|
|
<ele-pro-table
|
|
<ele-pro-table
|
|
|
ref="resourceTable"
|
|
ref="resourceTable"
|
|
@@ -982,7 +1003,7 @@
|
|
|
<el-button type="primary" @click="add">添加</el-button>
|
|
<el-button type="primary" @click="add">添加</el-button>
|
|
|
</template>
|
|
</template>
|
|
|
<template v-slot:action="{ row, $index }">
|
|
<template v-slot:action="{ row, $index }">
|
|
|
- <el-link type="danger" @click="handleDel(row, $index)"
|
|
|
|
|
|
|
+ <el-link type="danger" @click="handleDel(row, $index)"
|
|
|
>删除</el-link
|
|
>删除</el-link
|
|
|
>
|
|
>
|
|
|
</template>
|
|
</template>
|
|
@@ -1368,34 +1389,6 @@
|
|
|
minWidth: 90
|
|
minWidth: 90
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- {
|
|
|
|
|
- prop: 'weightUnit',
|
|
|
|
|
- label: '重量单位',
|
|
|
|
|
- showOverflowTooltip: true,
|
|
|
|
|
- minWidth: 90
|
|
|
|
|
- },
|
|
|
|
|
-
|
|
|
|
|
- {
|
|
|
|
|
- prop: 'roughWeight',
|
|
|
|
|
- label: '毛重',
|
|
|
|
|
- showOverflowTooltip: true,
|
|
|
|
|
- minWidth: 90
|
|
|
|
|
- },
|
|
|
|
|
-
|
|
|
|
|
- {
|
|
|
|
|
- prop: 'netWeight',
|
|
|
|
|
- label: '净重',
|
|
|
|
|
- showOverflowTooltip: true,
|
|
|
|
|
- minWidth: 90
|
|
|
|
|
- },
|
|
|
|
|
-
|
|
|
|
|
- {
|
|
|
|
|
- prop: 'packingUnit',
|
|
|
|
|
- align: 'center',
|
|
|
|
|
- label: '包装单位',
|
|
|
|
|
- showOverflowTooltip: true
|
|
|
|
|
- },
|
|
|
|
|
-
|
|
|
|
|
{
|
|
{
|
|
|
columnKey: 'action',
|
|
columnKey: 'action',
|
|
|
label: '操作',
|
|
label: '操作',
|
|
@@ -1511,6 +1504,7 @@
|
|
|
this.$refs.productRefs.open(row, '选择物料', '1', idx);
|
|
this.$refs.productRefs.open(row, '选择物料', '1', idx);
|
|
|
},
|
|
},
|
|
|
handleDel(row, index) {
|
|
handleDel(row, index) {
|
|
|
|
|
+
|
|
|
let type = '';
|
|
let type = '';
|
|
|
if (this.activeName === '材料定额') {
|
|
if (this.activeName === '材料定额') {
|
|
|
type = 'materialQuota';
|
|
type = 'materialQuota';
|
|
@@ -1524,9 +1518,10 @@
|
|
|
type = 'fileParam';
|
|
type = 'fileParam';
|
|
|
} else if (this.activeName === '标准产出') {
|
|
} else if (this.activeName === '标准产出') {
|
|
|
type = 'standardOutput';
|
|
type = 'standardOutput';
|
|
|
|
|
+ } else if (this.activeName === '关键设备') {
|
|
|
|
|
+ type = 'standardDevice';
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- console.log(this.currentIndex,44)
|
|
|
|
|
this.tableData.taskParam[this.currentIndex][type].splice(index, 1);
|
|
this.tableData.taskParam[this.currentIndex][type].splice(index, 1);
|
|
|
},
|
|
},
|
|
|
addProductList(list) {
|
|
addProductList(list) {
|
|
@@ -1605,7 +1600,10 @@
|
|
|
this.$refs.productMultipleRefs.open(1);
|
|
this.$refs.productMultipleRefs.open(1);
|
|
|
return;
|
|
return;
|
|
|
} else if (this.activeName === '标准产出') {
|
|
} else if (this.activeName === '标准产出') {
|
|
|
- this.$refs.standardOutputRefs.open();
|
|
|
|
|
|
|
+ this.$refs.standardOutputRefs.open(9);
|
|
|
|
|
+ return;
|
|
|
|
|
+ } else if (this.activeName === '关键设备') {
|
|
|
|
|
+ this.$refs.standardOutputRefs.open(4);
|
|
|
return;
|
|
return;
|
|
|
} else if (this.activeName === '制造资源') {
|
|
} else if (this.activeName === '制造资源') {
|
|
|
type = 'resource';
|
|
type = 'resource';
|
|
@@ -1706,6 +1704,10 @@
|
|
|
this.$refs.standard.setData(
|
|
this.$refs.standard.setData(
|
|
|
this.tableData.taskParam[this.currentIndex].standardOutput || []
|
|
this.tableData.taskParam[this.currentIndex].standardOutput || []
|
|
|
);
|
|
);
|
|
|
|
|
+ } else if (this.activeName === '关键设备') {
|
|
|
|
|
+ this.$refs.deviceTabRef.setData(
|
|
|
|
|
+ this.tableData.taskParam[this.currentIndex].standardDevice || []
|
|
|
|
|
+ );
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
openParam(type) {
|
|
openParam(type) {
|
|
@@ -1732,15 +1734,28 @@
|
|
|
);
|
|
);
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- chooseStandardList(data) {
|
|
|
|
|
|
|
+ chooseStandardList(type, data) {
|
|
|
let dom = null;
|
|
let dom = null;
|
|
|
- dom = this.$refs.standard;
|
|
|
|
|
- dom.setData([ data[0]]);
|
|
|
|
|
|
|
|
|
|
- this.$set(
|
|
|
|
|
- this.tableData.taskParam[this.currentIndex],
|
|
|
|
|
- dom.getData()
|
|
|
|
|
- );
|
|
|
|
|
|
|
+ if (type == 9) {
|
|
|
|
|
+ dom = this.$refs.standard;
|
|
|
|
|
+ dom.setData([data[0]]);
|
|
|
|
|
+
|
|
|
|
|
+ this.$set(
|
|
|
|
|
+ this.tableData.taskParam[this.currentIndex],
|
|
|
|
|
+ 'standardOutput',
|
|
|
|
|
+ dom.getData()
|
|
|
|
|
+ );
|
|
|
|
|
+ } else if (type == 4) {
|
|
|
|
|
+ dom = this.$refs.deviceTabRef;
|
|
|
|
|
+ dom.setData([data[0]]);
|
|
|
|
|
+
|
|
|
|
|
+ this.$set(
|
|
|
|
|
+ this.tableData.taskParam[this.currentIndex],
|
|
|
|
|
+ 'standardDevice',
|
|
|
|
|
+ dom.getData()
|
|
|
|
|
+ );
|
|
|
|
|
+ }
|
|
|
},
|
|
},
|
|
|
remove(row, type) {
|
|
remove(row, type) {
|
|
|
let dom = null;
|
|
let dom = null;
|