Browse Source

alpha是3,HT是5.4、天线是3.2

硬标西班牙的,框出来的部分可不可以设置成默认勾选?就跟上面那个品牌一样,导出界面打开时就默认勾选的“境外品牌”
master
han\hanst 2 weeks ago
parent
commit
2bfbe38c1d
  1. 43
      src/views/modules/ecss/declaration.vue

43
src/views/modules/ecss/declaration.vue

@ -2427,6 +2427,39 @@
} }
return ['02-Hardtag', '05-Alpha'].includes(this.currentRow.buNo) return ['02-Hardtag', '05-Alpha'].includes(this.currentRow.buNo)
}, },
isAlphaBu() {
if (!this.currentRow || !this.currentRow.buNo) {
return false
}
return ['05-Alpha'].includes(this.currentRow.buNo)
},
isHardtagOrAntennaBu() {
if (!this.currentRow || !this.currentRow.buNo) {
return false
}
return ['02-Hardtag', '04-MHM'].includes(this.currentRow.buNo)
},
isSpainDestination() {
if (!this.currentRow) {
return false
}
const destinationFields = [
this.currentRow.destination
]
return destinationFields.some(field => {
const text = field ? String(field).trim().toUpperCase() : ''
const normalizedText = text.normalize ? text.normalize('NFD').replace(/[\u0300-\u036f]/g, '') : text
return normalizedText.indexOf('SPAIN') > -1
|| normalizedText.indexOf('ESPANA') > -1
|| normalizedText.indexOf('西班牙') > -1
})
},
shouldEnableSpainDefaultChecks() {
return this.isHardtagOrAntennaBu() && this.isSpainDestination()
},
shouldEnableAlphaSpainDefaultChecks() {
return this.isAlphaBu() && this.isSpainDestination()
},
getPickupKeywordBySourceArea() { getPickupKeywordBySourceArea() {
const detailList = Array.isArray(this.dataList2) ? this.dataList2 : [] const detailList = Array.isArray(this.dataList2) ? this.dataList2 : []
const sourceArea = detailList const sourceArea = detailList
@ -2975,6 +3008,7 @@
this.exportGoods.hsCodeDescTypeBooking = 'N' this.exportGoods.hsCodeDescTypeBooking = 'N'
this.exportGoods.showOrderNoFlag = false this.exportGoods.showOrderNoFlag = false
this.exportGoods.showInvoiceFlag = false this.exportGoods.showInvoiceFlag = false
this.exportGoods.mexicoShippingMarkFlag = false
await this.loadPickupAddressList(this.currentRow.buNo) await this.loadPickupAddressList(this.currentRow.buNo)
//this.templateData.type='' //this.templateData.type=''
//await this.searchTemplateOne(); //await this.searchTemplateOne();
@ -2986,12 +3020,19 @@
if (this.packageUnit==='箱') { if (this.packageUnit==='箱') {
this.exportPaking.kgs=0.1 this.exportPaking.kgs=0.1
} }
if (this.currentRow.buNo==='05-Alpha' || this.currentRow.buNo==='04-MHM') {
if (this.currentRow.buNo==='05-Alpha') {
this.exportPaking.kgs=3 this.exportPaking.kgs=3
} else if (this.currentRow.buNo==='02-Hardtag'){ } else if (this.currentRow.buNo==='02-Hardtag'){
this.exportPaking.kgs=5.4 this.exportPaking.kgs=5.4
} else if (this.currentRow.buNo==='04-MHM'){
this.exportPaking.kgs=3.2
} }
this.exportPaking.shippingMark=this.buildDefaultShippingMark() this.exportPaking.shippingMark=this.buildDefaultShippingMark()
const shouldCheckSpainDefaults = this.shouldEnableSpainDefaultChecks()
this.exportInvoice.hsCodeFlag = shouldCheckSpainDefaults || this.shouldEnableAlphaSpainDefaultChecks()
this.exportPaking.packaging = shouldCheckSpainDefaults || this.shouldEnableAlphaSpainDefaultChecks()
this.exportGoods.showInvoiceFlag = shouldCheckSpainDefaults
this.exportGoods.mexicoShippingMarkFlag = shouldCheckSpainDefaults
if (this.currentRow.buNo==='03-RFID' || this.currentRow.buNo==='01-Label') { if (this.currentRow.buNo==='03-RFID' || this.currentRow.buNo==='01-Label') {
this.exportAllFlag = true this.exportAllFlag = true
} else { } else {

Loading…
Cancel
Save