|
|
|
|
@ -61,6 +61,24 @@ |
|
|
|
|
</el-form-item> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column align="center" label="设备" prop="device"> |
|
|
|
|
<template #header> |
|
|
|
|
<span><i style="color: red">*</i>设备</span> |
|
|
|
|
</template> |
|
|
|
|
<template #default="scope"> |
|
|
|
|
<el-form-item :prop="`tableData[${scope.$index}].device`" :rules="formRules.device"> |
|
|
|
|
<el-select v-model="scope.row.device" clearable filterable> |
|
|
|
|
<el-option |
|
|
|
|
v-for="item in scope.row.deviceOptions" |
|
|
|
|
:key="item.id" |
|
|
|
|
:label="item.name" |
|
|
|
|
:value="item.id" |
|
|
|
|
></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
|
|
|
|
|
<el-table-column align="center" label="规则类型" prop="ruleType"> |
|
|
|
|
<template #header> |
|
|
|
|
<span><i style="color: red">*</i>规则类型</span> |
|
|
|
|
@ -139,23 +157,25 @@ |
|
|
|
|
:prop="`tableData[${scope.$index}].cumulativeInitialValue`" |
|
|
|
|
:rules="formRules.cumulativeInitialValue" |
|
|
|
|
> --> |
|
|
|
|
<el-date-picker |
|
|
|
|
style="width: 100%" |
|
|
|
|
v-if=" |
|
|
|
|
scope.row.ruleType == 3 || |
|
|
|
|
scope.row.ruleType == 2 || |
|
|
|
|
scope.row.ruleType == 5 || |
|
|
|
|
scope.row.ruleType == 6 |
|
|
|
|
" |
|
|
|
|
v-model="scope.row.cumulativeInitialValue" |
|
|
|
|
type="date" |
|
|
|
|
placeholder="选择日期" |
|
|
|
|
value-format="YYYY-MM-DD" |
|
|
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
|
|
</el-date-picker> |
|
|
|
|
<el-input v-else v-model="scope.row.cumulativeInitialValue" :disabled="scope.row.ruleType == 4||scope.row.ruleType== 1"></el-input> |
|
|
|
|
<el-date-picker |
|
|
|
|
style="width: 100%" |
|
|
|
|
v-if=" |
|
|
|
|
scope.row.ruleType == 3 || |
|
|
|
|
scope.row.ruleType == 2 || |
|
|
|
|
scope.row.ruleType == 5 || |
|
|
|
|
scope.row.ruleType == 6 |
|
|
|
|
" |
|
|
|
|
v-model="scope.row.cumulativeInitialValue" |
|
|
|
|
type="date" |
|
|
|
|
placeholder="选择日期" |
|
|
|
|
value-format="YYYY-MM-DD" |
|
|
|
|
> |
|
|
|
|
</el-date-picker> |
|
|
|
|
<el-input |
|
|
|
|
v-else |
|
|
|
|
v-model="scope.row.cumulativeInitialValue" |
|
|
|
|
:disabled="scope.row.ruleType == 4 || scope.row.ruleType == 1" |
|
|
|
|
></el-input> |
|
|
|
|
<!-- </el-form-item> --> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
@ -175,7 +195,7 @@ |
|
|
|
|
import { getWorkCenterList } from '@/api/processManagement/addQuantity.js'; |
|
|
|
|
import { add, update } from '@/api/processManagement/planClass.js'; |
|
|
|
|
import { getTank } from '@/api/tankSolutionSystem/info'; |
|
|
|
|
|
|
|
|
|
import { getEquipmentList } from '@/api/processManagement/specialProcess'; |
|
|
|
|
export default { |
|
|
|
|
props: { |
|
|
|
|
showDialog: { type: Boolean, default: false }, |
|
|
|
|
@ -192,12 +212,12 @@ export default { |
|
|
|
|
label: '电量差类', |
|
|
|
|
value: 1, |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
{ |
|
|
|
|
label: '主盐添加量类', |
|
|
|
|
value: 4, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
{ |
|
|
|
|
label: '累计电量类', |
|
|
|
|
value: 2, |
|
|
|
|
}, |
|
|
|
|
@ -205,7 +225,7 @@ export default { |
|
|
|
|
label: '累计生产日期', |
|
|
|
|
value: 3, |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
{ |
|
|
|
|
label: '累计生产面积', |
|
|
|
|
value: 5, |
|
|
|
|
@ -270,6 +290,7 @@ export default { |
|
|
|
|
cumulativeInitialValue: [ |
|
|
|
|
{ required: true, message: '请输入', trigger: ['change', 'submit'] }, |
|
|
|
|
], |
|
|
|
|
device: [{ required: true, message: '请选择', trigger: ['change', 'submit'] }], |
|
|
|
|
}, |
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
|
@ -291,12 +312,18 @@ export default { |
|
|
|
|
this.form.batchNo = ''; |
|
|
|
|
console.log(this.form.tableData[index]); |
|
|
|
|
this.getTankList(this.form.tableData[index].wcId, index); |
|
|
|
|
this.getEquipmentList(this.form.tableData[index].wcId, index) |
|
|
|
|
}, // 查询作业槽下拉列表 |
|
|
|
|
getTankList(val, index) { |
|
|
|
|
getTank({ workstationId: val ? val : '' }).then(res => { |
|
|
|
|
this.form.tableData[index].batchNoOptions = res.data.data; |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
getEquipmentList(val, index) { |
|
|
|
|
getEquipmentList({ workstationId: val ? val : '' }).then(res => { |
|
|
|
|
this.form.tableData[index].deviceOptions = res.data.data; |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
getWorkCenterList() { |
|
|
|
|
getWorkCenterList().then(res => { |
|
|
|
|
this.wcData = res.data.data || []; |
|
|
|
|
|