|
|
|
@ -135,17 +135,7 @@ |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="model" label="规格"> </el-table-column> |
|
|
|
<el-table-column prop="model" label="规格"> </el-table-column> |
|
|
|
<el-table-column prop="type" label="类别"> |
|
|
|
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
{{ |
|
|
|
|
|
|
|
scope.row.type === "NY" |
|
|
|
|
|
|
|
? "耐用品" |
|
|
|
|
|
|
|
: scope.row.type === "YH" |
|
|
|
|
|
|
|
? "易耗品" |
|
|
|
|
|
|
|
: "" |
|
|
|
|
|
|
|
}} |
|
|
|
|
|
|
|
</template> |
|
|
|
|
|
|
|
</el-table-column> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<el-table-column prop="unit" label="单位"> </el-table-column> |
|
|
|
<el-table-column prop="unit" label="单位"> </el-table-column> |
|
|
|
<el-table-column |
|
|
|
<el-table-column |
|
|
|
@ -212,6 +202,17 @@ |
|
|
|
<span v-else>{{ scope.row.outboundQuantity }}</span> |
|
|
|
<span v-else>{{ scope.row.outboundQuantity }}</span> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table-column> |
|
|
|
|
|
|
|
<el-table-column prop="type" label="类别"> |
|
|
|
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
{{ |
|
|
|
|
|
|
|
scope.row.type === "NY" |
|
|
|
|
|
|
|
? "耐用品" |
|
|
|
|
|
|
|
: scope.row.type === "YH" |
|
|
|
|
|
|
|
? "易耗品" |
|
|
|
|
|
|
|
: "" |
|
|
|
|
|
|
|
}} |
|
|
|
|
|
|
|
</template> |
|
|
|
|
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
<el-table-column |
|
|
|
label="操作" |
|
|
|
label="操作" |
|
|
|
style="text-align: center" |
|
|
|
style="text-align: center" |
|
|
|
@ -517,13 +518,14 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
mounted() { |
|
|
|
mounted() { |
|
|
|
|
|
|
|
this.getDetailedItems(); |
|
|
|
this.outDialogVisible = this.repairVisible; |
|
|
|
this.outDialogVisible = this.repairVisible; |
|
|
|
if (this.outDialogType == "add") { |
|
|
|
if (this.outDialogType == "add") { |
|
|
|
this.addInit(); |
|
|
|
this.addInit(); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
this.inInit(); |
|
|
|
this.inInit(); |
|
|
|
} |
|
|
|
} |
|
|
|
this.getDetailedItems(); |
|
|
|
|
|
|
|
this.sizeForm.userInfoVO = this.userInfo; |
|
|
|
this.sizeForm.userInfoVO = this.userInfo; |
|
|
|
// this.getMaterialList() |
|
|
|
// this.getMaterialList() |
|
|
|
}, |
|
|
|
}, |
|
|
|
@ -782,20 +784,17 @@ export default { |
|
|
|
const selectedDept = this.departmentList.find( |
|
|
|
const selectedDept = this.departmentList.find( |
|
|
|
(dept) => dept.departmentId === this.inBatchForm.department |
|
|
|
(dept) => dept.departmentId === this.inBatchForm.department |
|
|
|
); |
|
|
|
); |
|
|
|
const deptName = selectedDept ? selectedDept.department : ""; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// this.sizeForm.inTableData = res.data.result.map((item) => ({ |
|
|
|
|
|
|
|
// ...item, |
|
|
|
|
|
|
|
// IdDemandEndld: this.inBatchForm.batchType, |
|
|
|
|
|
|
|
// department: deptName, |
|
|
|
|
|
|
|
// })); |
|
|
|
|
|
|
|
const processedData = res.data.result.map((item) => { |
|
|
|
const processedData = res.data.result.map((item) => { |
|
|
|
// 计算剩余可出库数量:申请数量 - 已出库数量 |
|
|
|
// 计算剩余可出库数量:申请数量 - 已出库数量 |
|
|
|
// 如果字段不存在,默认为 0 |
|
|
|
// 如果字段不存在,默认为 0 |
|
|
|
const appQty = Number(item.applicationQuantity || 0); |
|
|
|
const appQty = Number(item.applicationQuantity || 0); |
|
|
|
const outQty = Number(item.outboundQuantity || 0); |
|
|
|
const outQty = Number(item.outboundQuantity || 0); |
|
|
|
const defaultQty = appQty - outQty; |
|
|
|
const defaultQty = appQty - outQty; |
|
|
|
|
|
|
|
if (this.inBatchForm.optionType === "YH"){ |
|
|
|
|
|
|
|
item.department = selectedDept.departmentId |
|
|
|
|
|
|
|
item.departmentName = selectedDept.department |
|
|
|
|
|
|
|
} |
|
|
|
return { |
|
|
|
return { |
|
|
|
...item, |
|
|
|
...item, |
|
|
|
IdDemandEndld: this.inBatchForm.batchType, |
|
|
|
IdDemandEndld: this.inBatchForm.batchType, |
|
|
|
@ -823,6 +822,7 @@ export default { |
|
|
|
this.dialogVisible = true; |
|
|
|
this.dialogVisible = true; |
|
|
|
this.batchTableData = res.data.result; |
|
|
|
this.batchTableData = res.data.result; |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
|
|
|
|
|
|
|
|
this.getStatistics(); |
|
|
|
this.getStatistics(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|