From 109c83570a6c052c4c83633a0bce8ae81af97af2 Mon Sep 17 00:00:00 2001 From: spring <2396852758@qq.com> Date: 星期四, 20 二月 2025 17:04:07 +0800 Subject: [PATCH] 检验任务90% --- src/views/business/materialOrder/customsInspection.vue | 90 ++++++++++++++++++++------------------------ 1 files changed, 41 insertions(+), 49 deletions(-) diff --git a/src/views/business/materialOrder/customsInspection.vue b/src/views/business/materialOrder/customsInspection.vue index 6623b90..f54eec2 100644 --- a/src/views/business/materialOrder/customsInspection.vue +++ b/src/views/business/materialOrder/customsInspection.vue @@ -388,7 +388,7 @@ width="32%"> <span>{{ dialogMessage }}</span> <span slot="footer" class="dialog-footer"> - <el-button type="primary" @click="this.goBack()">纭� 瀹�</el-button> + <el-button type="primary" @click="goBack()">纭� 瀹�</el-button> </span> </el-dialog> <el-dialog @@ -431,8 +431,8 @@ </template> <script> -import ValueTable from "@/components/Table/value-table.vue"; import { + addExemptionOrder, addInsOrder, addRawMaterOrderTemplate, delRawMaterOrderTemplate, getInsOrder, @@ -444,9 +444,7 @@ export default { name: "CustomsInspection", dicts: ['check_type', 'urgency_level'], - components: { - ValueTable, - }, + components: {}, props: { currentId: { type: Number, @@ -765,12 +763,10 @@ this.selectTree = str.join(' - ') this.addListInfo(this.codeLevel, res.data) // 鍘熸潗鏂欐牱鍝佹槸鍥哄畾鐨勶紝灏遍粯璁よ祴鍊间竴鏉℃暟鎹紝鍙媶鍒� this.selectInsOrderTemplate() // 鍘熸潗鏂欐ā鏉垮垪琛ㄦ煡璇� - } else { - this.dialogVisible = true - this.dialogMessage = res.message } }).catch(err => { - console.log('err---', err) + this.dialogVisible = true + this.dialogMessage = err.message }) } }, @@ -1000,28 +996,26 @@ this.addObj.ifsInventoryId = this.customsInspection.id this.noNeedCheckLoad = true addExemptionOrder({ - str: JSON.stringify({ - insOrder: this.addObj, - list: JSON.stringify(sampleList.map(a => { - if (a.modelNum) { - // 鏍规嵁x鍙峰垽鏂瀷鍙峰弬鏁颁笌鏍峰搧鍨嬪彿鐨勬嫾鎺ヤ綅缃� - // 渚嬪脳4锛屽氨涓�500ML脳4锛�4脳锛屽氨涓�4脳500ML - const index = a.modelNum.indexOf('脳') - if (index === 0) { - a.model = a.model + a.modelNum - } else if (index === -1) { - a.model = a.model + '-' + a.modelNum - } else { - a.model = a.modelNum + a.model - } + insOrder: this.addObj, + list: sampleList.map(a => { + if (a.modelNum) { + // 鏍规嵁x鍙峰垽鏂瀷鍙峰弬鏁颁笌鏍峰搧鍨嬪彿鐨勬嫾鎺ヤ綅缃� + // 渚嬪脳4锛屽氨涓�500ML脳4锛�4脳锛屽氨涓�4脳500ML + const index = a.modelNum.indexOf('脳') + if (index === 0) { + a.model = a.model + a.modelNum + } else if (index === -1) { + a.model = a.model + '-' + a.modelNum } else { - a.model = a.model + ((a.modelNum == null || a.modelNum == '' || a.modelNum == 'null') ? '' : ('-' + a.modelNum)) + a.model = a.modelNum + a.model } - a.insProduct = a.insProduct.filter(b=>b.state === 1) - return a - })), - pairing: JSON.stringify(pairing) - }) + } else { + a.model = a.model + ((a.modelNum == null || a.modelNum == '' || a.modelNum == 'null') ? '' : ('-' + a.modelNum)) + } + a.insProduct = a.insProduct.filter(b=>b.state === 1) + return a + }), + pairing: pairing }).then(res => { this.noNeedCheckLoad = false if (res.code == 201) return @@ -1051,28 +1045,26 @@ this.addObj.ifsInventoryId = this.customsInspection.id this.saveLoad = true addInsOrder({ - str: JSON.stringify({ - insOrder: this.addObj, - list: JSON.stringify(sampleList.map(a => { - if (a.modelNum) { - // 鏍规嵁x鍙峰垽鏂瀷鍙峰弬鏁颁笌鏍峰搧鍨嬪彿鐨勬嫾鎺ヤ綅缃� - // 渚嬪脳4锛屽氨涓�500ML脳4锛�4脳锛屽氨涓�4脳500ML - const index = a.modelNum.indexOf('脳') - if (index === 0) { - a.model = a.model + a.modelNum - } else if (index === -1) { - a.model = a.model + '-' + a.modelNum - } else { - a.model = a.modelNum + a.model - } + insOrder: this.addObj, + list: sampleList.map(a => { + if (a.modelNum) { + // 鏍规嵁x鍙峰垽鏂瀷鍙峰弬鏁颁笌鏍峰搧鍨嬪彿鐨勬嫾鎺ヤ綅缃� + // 渚嬪脳4锛屽氨涓�500ML脳4锛�4脳锛屽氨涓�4脳500ML + const index = a.modelNum.indexOf('脳') + if (index === 0) { + a.model = a.model + a.modelNum + } else if (index === -1) { + a.model = a.model + '-' + a.modelNum } else { - a.model = a.model + ((a.modelNum == null || a.modelNum == '' || a.modelNum == 'null') ? '' : ('-' + a.modelNum)) + a.model = a.modelNum + a.model } - a.insProduct = a.insProduct.filter(b=>b.state === 1) - return a - })), - pairing: JSON.stringify(pairing) - }) + } else { + a.model = a.model + ((a.modelNum == null || a.modelNum == '' || a.modelNum == 'null') ? '' : ('-' + a.modelNum)) + } + a.insProduct = a.insProduct.filter(b=>b.state === 1) + return a + }), + pairing: pairing }).then(res => { this.saveLoad = false if (res.code == 201) return -- Gitblit v1.9.3