diff --git a/src/views/mes/pro/process/index.vue b/src/views/mes/pro/process/index.vue index 933fa79..5572026 100644 --- a/src/views/mes/pro/process/index.vue +++ b/src/views/mes/pro/process/index.vue @@ -255,14 +255,6 @@ - 重置 - + @@ -320,16 +312,17 @@ /> - - + @@ -522,6 +515,12 @@ export default { this.reset(); }, + // 取消按钮 + equipmentCancel() { + this.boundeEuipmentOpen = false; + this.reset(); + }, + // 表单重置 reset() { this.form = { @@ -536,7 +535,7 @@ export default { updateTime: null, fileList:'', equipmentTypeName:'', - equipmentId :this.equipmentId, + equipmentId :null, equipmentTypeName :null, equipmentTypeCode:null, equipmentName :null, @@ -638,34 +637,16 @@ export default { }); }, - submitEquipmentForm(row) { - //正确 - // this.reset(); - // const processId = row.processId; - // this.form.processId = processId; - // const equipmentId = row.equipmentId || this.ids; - // console.log(equipmentId,1); - // if (equipmentId != null) { - // this.form.equipmentId = equipmentId.toString(); - // updateProcess(this.form,processId).then(response => { - // this.$modal.msgSuccess("关联成功"); - // }); - // } - //this.reset(); - const processId = this.ids1; - this.queryEquipmentParams.processId = processId; - const equipmentId = row.equipmentId || this.ids; - console.log(equipmentId,1); - if (equipmentId != null) { - this.queryEquipmentParams.processId = processId.toString(); - this.queryEquipmentParams.equipmentId = equipmentId.toString(); - updateProcess(this.queryEquipmentParams).then(response => { - this.$modal.msgSuccess("关联成功"); - this.boundeEuipmentOpen = false; - this.activated(); - this.getList(); - }); - } + // + submitEquipmentForm() { + const table = this.$refs.myTable; + const data = table.data; + console.log(data); + for (const one of data) { + const equipmentCode = one.equipmentCode; + this.form.workCenter = this.form.workCenter + ','+ equipmentCode; + this.boundeEuipmentOpen = false; + } }, /** 删除按钮操作 */