退料接收优化zzy

This commit is contained in:
zzyuan 2024-04-26 18:11:19 +08:00
parent e10c810281
commit 5751307d15
1 changed files with 16 additions and 4 deletions

View File

@ -72,7 +72,7 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="类型名称" align="center" prop="typeName" :show-overflow-tooltip="true" /> <el-table-column label="类型名称" align="center" prop="typeName" :show-overflow-tooltip="true" />
<el-table-column type="expand" v-if="isView"> <el-table-column type="expand" v-if="isPlural">
<template slot-scope="scope"> <template slot-scope="scope">
<div class="nested-table-container"> <div class="nested-table-container">
<el-table :data="scope.row.maTypeDetails" style="width: 100%"> <el-table :data="scope.row.maTypeDetails" style="width: 100%">
@ -450,6 +450,7 @@ export default {
// //
title: '', title: '',
isView: false, // isView: false, //
isPlural:false,
dialogIsView: false, // dialogIsView: false, //
openIn: false, openIn: false,
// //
@ -543,7 +544,18 @@ export default {
getList() { getList() {
this.loading = true this.loading = true
receiveView(this.queryParams).then(response => { receiveView(this.queryParams).then(response => {
this.deviceList = response.data.rows this.deviceList = response.data.rows;
this.deviceList.forEach(item=>{
if(item.manageType=='0'||item.manageType=='1'){
item.partNum = item.num
}else{
item.partNum = item.partNum
}
if(item.maTypeDetails.length>0){
this.isPlural=true;
}
})
this.total = response.data.total this.total = response.data.total
this.loading = false this.loading = false
}).catch(() => { }).catch(() => {
@ -863,7 +875,7 @@ export default {
arr = this.codeSelectList.map(item => { arr = this.codeSelectList.map(item => {
return { return {
parentId: this.codeQuery.parentId, parentId: this.codeQuery.parentId,
typeId: item.modelId, typeId: item.typeId,
backNum: 1, backNum: 1,
backStatus: type, backStatus: type,
manageType: 0, manageType: 0,
@ -875,7 +887,7 @@ export default {
taskId: this.codeQuery.taskId, taskId: this.codeQuery.taskId,
arr: arr, arr: arr,
} }
// console.log(param) console.log(param)
setCodeBack(param).then(response => { setCodeBack(param).then(response => {
if (response.code == 200) { if (response.code == 200) {
this.$modal.msgSuccess('操作成功') this.$modal.msgSuccess('操作成功')