|
|
|
|
@ -48,7 +48,7 @@ |
|
|
|
|
<script> |
|
|
|
|
import addAccumulateClass from './components/addAccumulateClassDialog.vue'; |
|
|
|
|
import maintainDialog from './components/maintainDialog.vue'; |
|
|
|
|
import { getList, add, remove, update } from '@/api/processManagement/planClass.js'; |
|
|
|
|
import { getList, add, remove, update,batchReset } from '@/api/processManagement/planClass.js'; |
|
|
|
|
|
|
|
|
|
export default { |
|
|
|
|
components: { |
|
|
|
|
@ -175,6 +175,27 @@ export default { |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'left', |
|
|
|
|
width: 120, |
|
|
|
|
editDisplay:false, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '设备名称', |
|
|
|
|
prop: 'device', |
|
|
|
|
hide:true, |
|
|
|
|
search: false, |
|
|
|
|
sortable: true, |
|
|
|
|
overHidden: true, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'left', |
|
|
|
|
width: 120, |
|
|
|
|
dicUrl: `/blade-desk/equipment/page?used=1&workstationId={{wcId}}&size=99999`, |
|
|
|
|
props: { |
|
|
|
|
label: 'deviceName', |
|
|
|
|
value: 'id', |
|
|
|
|
res: 'data.records', |
|
|
|
|
}, |
|
|
|
|
change: (val) =>{ |
|
|
|
|
this.equipmentChange(val.item,'equipmentId') |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '规则类型', |
|
|
|
|
@ -375,6 +396,11 @@ export default { |
|
|
|
|
}, |
|
|
|
|
mounted() {}, |
|
|
|
|
methods: { |
|
|
|
|
equipmentChange(val,type){ |
|
|
|
|
if(val&&type=='equipmentId'){ |
|
|
|
|
this.form.deviceName = val.deviceName |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
// 关闭弹窗 |
|
|
|
|
closeDialog() { |
|
|
|
|
this.showMaintain = false; |
|
|
|
|
@ -396,11 +422,29 @@ export default { |
|
|
|
|
this.$message.error('请先选择数据'); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
this.maintainData = this.selectionList; |
|
|
|
|
this.title = ' 批量维护'; |
|
|
|
|
// this.showMaintain = true; |
|
|
|
|
this.showDialog = true; |
|
|
|
|
this.moldAddMore = false; |
|
|
|
|
// batchReset |
|
|
|
|
this.$confirm('确定将选择数据批量重置?', { |
|
|
|
|
confirmButtonText: '确定', |
|
|
|
|
cancelButtonText: '取消', |
|
|
|
|
type: 'warning', |
|
|
|
|
}) |
|
|
|
|
.then(() => { |
|
|
|
|
let ids=this.selectionList.map(item=>item.id) |
|
|
|
|
return batchReset({ids:ids.join(',')}); |
|
|
|
|
}) |
|
|
|
|
.then(() => { |
|
|
|
|
this.onLoad(this.page); |
|
|
|
|
this.$message({ |
|
|
|
|
type: 'success', |
|
|
|
|
message: '操作成功!', |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
// this.maintainData = this.selectionList; |
|
|
|
|
// this.title = ' 批量维护'; |
|
|
|
|
// // this.showMaintain = true; |
|
|
|
|
// this.showDialog = true; |
|
|
|
|
// this.moldAddMore = false; |
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
handleDelete() { |
|
|
|
|
if (this.selectionList.length == 0) { |
|
|
|
|
|