|
@@ -150,7 +150,7 @@
|
|
|
|
|
|
|
|
<!-- 操作列 -->
|
|
<!-- 操作列 -->
|
|
|
<template v-slot:action="{ row }">
|
|
<template v-slot:action="{ row }">
|
|
|
- <el-popconfirm class="ele-action" title="确定要删除当前工序吗?" @confirm="remove(row)">
|
|
|
|
|
|
|
+ <el-popconfirm class="ele-action" title="确定要删除当前参数吗?" @confirm="remove(row)">
|
|
|
<template v-slot:reference>
|
|
<template v-slot:reference>
|
|
|
<el-link type="danger" :underline="false" icon="el-icon-delete">
|
|
<el-link type="danger" :underline="false" icon="el-icon-delete">
|
|
|
删除
|
|
删除
|
|
@@ -244,7 +244,8 @@ export default {
|
|
|
loading: false,
|
|
loading: false,
|
|
|
// 是否是修改
|
|
// 是否是修改
|
|
|
isUpdate: false,
|
|
isUpdate: false,
|
|
|
-
|
|
|
|
|
|
|
+ tableData: [],
|
|
|
|
|
+ removeList: [],
|
|
|
|
|
|
|
|
// 表格列配置
|
|
// 表格列配置
|
|
|
columns: [
|
|
columns: [
|
|
@@ -311,6 +312,7 @@ export default {
|
|
|
showOverflowTooltip: true
|
|
showOverflowTooltip: true
|
|
|
}
|
|
}
|
|
|
],
|
|
],
|
|
|
|
|
+
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
@@ -351,7 +353,8 @@ export default {
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
openParam() {
|
|
openParam() {
|
|
|
- this.$refs.paramRefs.open(this.form.taskParam)
|
|
|
|
|
|
|
+ this.tableData = this.$refs.table.getData()
|
|
|
|
|
+ this.$refs.paramRefs.open(this.tableData)
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
@@ -361,7 +364,18 @@ export default {
|
|
|
this.$refs.table.setData([...arr, ...this.$refs.table.getData()]);
|
|
this.$refs.table.setData([...arr, ...this.$refs.table.getData()]);
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
|
|
+ remove(row) {
|
|
|
|
|
+ const data = this.$refs.table.getData() ?? [];
|
|
|
|
|
|
|
|
|
|
+ if (row.id) {
|
|
|
|
|
+ this.removeList.push(row.id);
|
|
|
|
|
+ this.$refs.table.setData(data.filter((d) => d.id !== row.id));
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.$refs.table.setData(
|
|
|
|
|
+ data.filter((d) => d.paramId !== row.paramId)
|
|
|
|
|
+ );
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
|
|
|
/* 保存编辑 */
|
|
/* 保存编辑 */
|
|
|
save() {
|
|
save() {
|