|
@ -481,20 +481,25 @@ const footButtonClick = async (val) => { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
const pointLabel = async () => { |
|
|
const pointLabel = async () => { |
|
|
const array =detatableData1.value.map(item=>{ |
|
|
// const array =detatableData1.value.map(item=>{ |
|
|
return { |
|
|
// return { |
|
|
packingNumber:item.number, |
|
|
// packingNumber:item.number, |
|
|
batch: item.batch, |
|
|
// batch: item.batch, |
|
|
printQty:item.printQty, |
|
|
// printQty:item.printQty, |
|
|
|
|
|
// } |
|
|
|
|
|
// }) |
|
|
|
|
|
const obj = { |
|
|
|
|
|
itemCode:detatableData1.value[0].itemCode, |
|
|
|
|
|
packingNumber:detatableData1.value[0].number, |
|
|
|
|
|
batch:detatableData1.value[0].batch, |
|
|
|
|
|
printQty:detatableData1.value[0].printQty, |
|
|
} |
|
|
} |
|
|
}) |
|
|
// const isHave = detatableData1.value.find(item => parseFloat(item.printQty) <= 0) |
|
|
console.log(array) |
|
|
if(!parseFloat(obj.printQty) ){ |
|
|
const isHave = detatableData1.value.find(item => parseFloat(item.printQty) <= 0) |
|
|
message.error(`物料号${obj.itemCode}打印数量不可以为0`) |
|
|
if(isHave){ |
|
|
|
|
|
message.error(`物料号${isHave.itemCode}打印数量不可以为0`) |
|
|
|
|
|
return; |
|
|
return; |
|
|
} |
|
|
} |
|
|
await PackageApi.batchPrintingLable({pointParams:array}).then(res => { |
|
|
await PackageApi.batchPrintingLableGet(obj).then(res => { |
|
|
const src = ref(BASE_URL + '/jmreport/view/922734157577715712?token=' + getAccessToken()) |
|
|
const src = ref(BASE_URL + '/jmreport/view/922734157577715712?token=' + getAccessToken()) |
|
|
window.open(src.value+'&asn_number='+res) |
|
|
window.open(src.value+'&asn_number='+res) |
|
|
}).catch(err => { |
|
|
}).catch(err => { |
|
|