Browse Source

一键导出的托和箱默认逻辑,如果装箱数据托数不为0,那么默认拖,如果装箱数据托数位0,那么默认箱

java8
han\hanst 5 months ago
parent
commit
cc3b2f651f
  1. 2
      src/views/modules/ecss/codelnotifyConfirm.vue
  2. 30
      src/views/modules/ecss/declaration.vue

2
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()

30
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

Loading…
Cancel
Save