批量打印调整

This commit is contained in:
wuteng 2025-08-13 10:18:28 +08:00
parent 3c513f2c91
commit cee3faed3f

View File

@ -402,15 +402,22 @@
}
}
}else{
newOrderList=[...orderList];
}
// else{
// newOrderList=[...orderList];
// }
// console.log("tnprint===>",newOrderList);
// console.log("tnprint===>",that.selTplCode);
this.printOrderList=newOrderList;
// this.printOrderList=newOrderList;
this.selTplCode.forEach(item=>{
that.tanexPrinter.batchPrint(item,that.selPrinterName,newOrderList,this.printManCode)
let paramsOrderList = [];
if(item=="TAN-GC-130" || item=="TAN-ENGC-130" || item=="VT-ENNOLOGO"){
paramsOrderList = newOrderList;
}else{
paramsOrderList = [...orderList]
}
that.tanexPrinter.batchPrint(item,that.selPrinterName,paramsOrderList,this.printManCode)
})
},
@ -548,15 +555,16 @@
}
}
}else{
newOrderList=[...orderList];
}
// else{
// newOrderList=[...orderList];
// }
const loadingInstance = this.$loading({
text: '正在生成预览...'
})
this.printOrderList=newOrderList;
// this.printOrderList=newOrderList;
let orderSeqMap = new Map();
for(let i=0; i<newOrderList.length; i++){
@ -573,7 +581,13 @@
// that.showCounter++;
// console.log('promise',this.tanexPrinter.batchGetPDF(this.selTplCode[0], this.selPrinterName, newOrderList, this.printManCode,async function(code,msg,data){}))
this.selTplCode.forEach(element => {
this.tanexPrinter.batchGetPDF(element,this.selPrinterName,newOrderList,this.printManCode,async function(code,msg,data){
let paramsOrderList=[];
if(element=="TAN-GC-130"|| element=='TAN-ENGC-130' || element=='VT-ENNOLOGO' ){
paramsOrderList = newOrderList // 子单号
}else{
paramsOrderList = [...orderList] // 主单号
}
this.tanexPrinter.batchGetPDF(element,this.selPrinterName,paramsOrderList,this.printManCode,async function(code,msg,data){
loadingInstance.close();
if(code == 500){