From cc3b2f651f8458320299e70f92706404b1c82df2 Mon Sep 17 00:00:00 2001 From: "han\\hanst" Date: Fri, 3 Oct 2025 21:30:29 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=80=E9=94=AE=E5=AF=BC=E5=87=BA=E7=9A=84?= =?UTF-8?q?=E6=89=98=E5=92=8C=E7=AE=B1=E9=BB=98=E8=AE=A4=E9=80=BB=E8=BE=91?= =?UTF-8?q?=EF=BC=8C=E5=A6=82=E6=9E=9C=E8=A3=85=E7=AE=B1=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E6=89=98=E6=95=B0=E4=B8=8D=E4=B8=BA0=EF=BC=8C=E9=82=A3?= =?UTF-8?q?=E4=B9=88=E9=BB=98=E8=AE=A4=E6=8B=96=EF=BC=8C=E5=A6=82=E6=9E=9C?= =?UTF-8?q?=E8=A3=85=E7=AE=B1=E6=95=B0=E6=8D=AE=E6=89=98=E6=95=B0=E4=BD=8D?= =?UTF-8?q?0=EF=BC=8C=E9=82=A3=E4=B9=88=E9=BB=98=E8=AE=A4=E7=AE=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/modules/ecss/codelnotifyConfirm.vue | 2 ++ src/views/modules/ecss/declaration.vue | 30 ++++++++++++++++++- 2 files changed, 31 insertions(+), 1 deletion(-) diff --git a/src/views/modules/ecss/codelnotifyConfirm.vue b/src/views/modules/ecss/codelnotifyConfirm.vue index 91d11a2..bb7a3aa 100644 --- a/src/views/modules/ecss/codelnotifyConfirm.vue +++ b/src/views/modules/ecss/codelnotifyConfirm.vue @@ -2101,6 +2101,8 @@ }) return false } + // 添加更新人信息 + this.confirmModel.updateBy = this.$store.state.user.name updateEcssDel(this.confirmModel).then(({data}) => { if (data && data.code === 0) { this.searchTable() diff --git a/src/views/modules/ecss/declaration.vue b/src/views/modules/ecss/declaration.vue index aa73c7f..0e53cf2 100644 --- a/src/views/modules/ecss/declaration.vue +++ b/src/views/modules/ecss/declaration.vue @@ -824,7 +824,8 @@ getNotifyPartDetail, getCustomerInfo, searchTemplateList, - getPropertiesListByDeclaration + getPropertiesListByDeclaration, + searchEcssCoDelPalletHeaderData }from "@/api/ecss/ecss.js" import { getTableUserListLanguage} from "@/api/table.js" import {getTableDefaultListLanguage} from "../../../api/table"; @@ -2239,6 +2240,33 @@ this.exportHeader.arrivalCountry = this.currentRow.receiveArea || '' this.exportHeader.tradeCountry = this.currentRow.salesArea || '' + // 获取装箱数据,根据托数设置托/箱默认值 + try { + // 只传递必要的字段,避免日期格式问题 + const queryData = { + site: this.currentRow.site, + buNo: this.currentRow.buNo, + delNo: this.currentRow.delNo + } + const palletData = await searchEcssCoDelPalletHeaderData(queryData) + if (palletData && palletData.data && palletData.data.code === 0) { + const palletList = palletData.data.rows || [] + // 计算总托数 + const totalPalletQty = palletList.reduce((sum, item) => { + return sum + (item.palletQty || 0) + }, 0) + // 根据托数设置默认值:托数不为0选择"托",托数为0选择"箱" + this.packageUnit = totalPalletQty > 0 ? '托' : '箱' + } else { + // 如果获取装箱数据失败,默认选择"箱" + this.packageUnit = '箱' + } + } catch (error) { + console.error('获取装箱数据失败:', error) + // 如果获取装箱数据失败,默认选择"箱" + this.packageUnit = '箱' + } + // 报关要素 this.brandType='境外品牌(其他)' this.exportAllFlag = true