巡检计划修改+删除

yangwl
wws 1 year ago
parent 9ba845c490
commit 911336944e

@ -229,7 +229,7 @@
>删除
</el-button>
</el-col>
<el-col :span="1.5">
<el-col v-if="false" :span="1.5">
<el-button
type="warning"
plain
@ -586,6 +586,7 @@ import {
formatEquItem,
getPersonList, getWorkCenter, initUpdatePlanInfo
} from "@/api/device/plan";
import plan from "@/views/plan/plan/index.vue";
export default {
name: "Plan",
@ -594,8 +595,6 @@ export default {
return {
//
changeCenter() {
console.log("改变了工作中心")
console.log(this.form.planWorkshop)
},
// list
@ -750,8 +749,6 @@ export default {
},
//
standardBtn() {
console.log("这里是你要确定的数据");
console.log(this.form.equipmentItem)
this.editorItem = false;
},
//
@ -766,19 +763,13 @@ export default {
},
// -
editorTheItem(e) {
console.log(e)
//
this.itemDetailList = [];
console.log("12312312")
console.log(e.equCheckItemList)
//
if (e.equCheckItemList == null) {
// -
console.log("出现了")
console.log(e.equPlanDetailList)
for (let i = 0; i < e.equPlanDetailList.length; i++) {
for (let j = 0; j < e.equPlanDetailList[i].equPlanStandardList.length; j++) {
@ -825,9 +816,6 @@ export default {
},
// -
delTheEquItem(e) {
console.log("删除")
console.log(e)
console.log(this.form.equipmentItem)
this.form.equipmentItem.splice(e.equipmentCode, 1)
},
//
@ -847,8 +835,6 @@ export default {
//
formatEquItem(this.selectEquList).then(response => {
console.log("开始格式化设备信息")
console.log(response)
for (let i = 0; i < response.data.length; i++) {
this.form.equipmentItem.push(response.data[i]);
@ -860,8 +846,6 @@ export default {
},
//
selectChangeEqu(e) {
console.log("这里!!!!!")
console.log(e)
this.selectEquList = e;
},
//
@ -990,8 +974,7 @@ export default {
//
setWorkCenter() {
getWorkCenter().then(response => {
console.log("这里是工作中心")
console.log(response.data)
this.workCenterList = response.data;
})
},
@ -1008,9 +991,6 @@ export default {
this.setWorkCenter();
initUpdatePlanInfo(row).then(response => {
console.log(row)
console.log("返回数据如下")
console.log(response.data)
this.form = response.data;
this.selectPersonList = response.data.personListVO;
@ -1080,8 +1060,6 @@ export default {
});
} else {
this.form.personList = this.selectPersonList;
console.log("这里是人员信息")
console.log(this.form.personList)
addPlan(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
@ -1094,7 +1072,26 @@ export default {
/** 删除按钮操作 */
handleDelete(row) {
const planIds = row.planId || this.ids;
this.$modal.confirm('是否确认删除计划编号为"' + planIds + '"的数据项?').then(function () {
var planCodes = '';
//
for (let i = 0; i < this.planList.length; i++) {
for (let j = 0; j < planIds.length; j++) {
if (planIds[j] == this.planList[i].planId) {
planCodes = planCodes + this.planList[i].planCode + ',';
}
}
}
if (planCodes == '') {
for (let i = 0; i < this.planList.length; i++) {
if (planIds == this.planList[i].planId) {
planCodes = this.planList[i].planCode;
}
}
}
this.$modal.confirm('是否确认删除计划编号为"' + planCodes + '"的数据项?').then(function () {
return delPlan(planIds);
}).then(() => {
this.getList();
@ -1120,6 +1117,7 @@ export default {
.my-step-body {
margin-top: 15px;
}
.el-transfer-panel {
width: 300px;
}

Loading…
Cancel
Save