diff --git a/src/printFormat/RF_RFID.js b/src/printFormat/RF_RFID.js index 9bfe1df..368c57f 100644 --- a/src/printFormat/RF_RFID.js +++ b/src/printFormat/RF_RFID.js @@ -25,7 +25,7 @@ export const printRF_RFIDLabel = (printList, icons, printerName,testFlag = false LODOP.NewPageA(); LODOP.PRINT_INITA(offsetY,offsetX,1100,512) LODOP.SET_PRINTER_INDEXA(printerName) - LODOP.SET_PRINT_PAGESIZE(direction === 'Vertical'?2:0,1100,512,""); + LODOP.SET_PRINT_PAGESIZE(direction === 'Vertical'?0:0,1100,512,""); LODOP.ADD_PRINT_IMAGE(-5,20,"26mm","26mm",row.qrCode); LODOP.SET_PRINT_STYLEA(0,"Stretch",1); LODOP.ADD_PRINT_IMAGE(4,+255,90,16,""); diff --git a/src/printFormat/alphaHardTagPrintFormat.js b/src/printFormat/alphaHardTagPrintFormat.js index 8193bb9..15489db 100644 --- a/src/printFormat/alphaHardTagPrintFormat.js +++ b/src/printFormat/alphaHardTagPrintFormat.js @@ -35,8 +35,6 @@ export function printAlphaHardTagLabel (printList, icons, printerName, flag) { } //如果打印正常的标签 LODOP.NewPageA(); - LODOP.PRINT_INITA(offsetY,offsetX,1100,512) - LODOP.SET_PRINTER_INDEXA(printerName) if (flag === 'Y'){ if (row.printLabelType === 0){ sizeTop = 190; @@ -44,13 +42,19 @@ export function printAlphaHardTagLabel (printList, icons, printerName, flag) { sizeTop = 0; } if (row.printLabelType === 0 || row.printLabelType === 1){ - printCartonLabel(LODOP,row,icons,direction === 'Vertical'?2:0) // 箱标签 + LODOP.PRINT_INITA(offsetY,offsetX,1100,512) + LODOP.SET_PRINTER_INDEXA(printerName) + printCartonLabel(LODOP,row,icons,direction === 'Vertical'?0:0) // 箱标签 } if (row.printLabelType === 0 || row.printLabelType === 2){ - printProductLabel(LODOP,row,direction === 'Vertical'?2:0) + LODOP.PRINT_INITA(offsetY,offsetX,1100,512) + LODOP.SET_PRINTER_INDEXA(printerName) + printProductLabel(LODOP,row,direction === 'Vertical'?0:0) } }else { - printCartonLabel(LODOP,row,icons,direction === 'Vertical'?2:0) // 箱标签 + LODOP.PRINT_INITA(offsetY,offsetX,1100,512) + LODOP.SET_PRINTER_INDEXA(printerName) + printCartonLabel(LODOP,row,icons,direction === 'Vertical'?0:0) // 箱标签 } LODOP.PRINT() } diff --git a/src/printFormat/antenna.js b/src/printFormat/antenna.js index eb7efe1..83055be 100644 --- a/src/printFormat/antenna.js +++ b/src/printFormat/antenna.js @@ -42,13 +42,13 @@ export const printAntennaLabel = (printList, icons, printerName,flag,testFlag = sizeTop = 0; } if (row.printLabelType === 0 || row.printLabelType === 1){ - printLabel(LODOP,row,icons,direction === 'Vertical'?2:0) // 箱标签 + printLabel(LODOP,row,icons,direction === 'Vertical'?0:0) // 箱标签 } if (row.printLabelType === 0 || row.printLabelType === 2){ - printProductLabel(LODOP,row,direction === 'Vertical'?2:0) + printProductLabel(LODOP,row,direction === 'Vertical'?0:0) } }else { - printLabel(LODOP,row,icons,direction === 'Vertical'?2:0) // 箱标签 + printLabel(LODOP,row,icons,direction === 'Vertical'?0:0) // 箱标签 } } //LODOP.PREVIEW(); diff --git a/src/printFormat/logisticLabel.js b/src/printFormat/logisticLabel.js index f214d32..1e2110c 100644 --- a/src/printFormat/logisticLabel.js +++ b/src/printFormat/logisticLabel.js @@ -24,7 +24,7 @@ const ckpLogo = 'iVBORw0KGgoAAAANSUhEUgAAAlkAAABxCAYAAADmmLY1AAAAAXNSR0IArs4c6QA LODOP.NewPageA(); LODOP.PRINT_INITA(offsetY,offsetX,1100,512) LODOP.SET_PRINTER_INDEXA(printerName) - LODOP.SET_PRINT_PAGESIZE(direction === 'Vertical'?2:0,1100,512,""); + LODOP.SET_PRINT_PAGESIZE(direction === 'Vertical'?0:0,1100,512,""); LODOP.ADD_PRINT_IMAGE(-5,20,"26mm","26mm",row.qrCode); LODOP.SET_PRINT_STYLEA(0,"Stretch",1); LODOP.ADD_PRINT_IMAGE(4,255,90,16,""); diff --git a/src/views/modules/label/printer.vue b/src/views/modules/label/printer.vue index 200cad0..ecbf34a 100644 --- a/src/views/modules/label/printer.vue +++ b/src/views/modules/label/printer.vue @@ -906,8 +906,8 @@ export default { }else if (item.printType === 'RF' || this.currentPart.category === 'RFID'){ printRF_RFIDLabel([params],icons,item.printerName,this.printTest) } - this.printTest = false } + this.printTest = false // let notFound = []; // // 打印机集合 // let labelList = this.labelFormatList.filter((item)=> item.labelType === 'Shipment Carton') @@ -1259,12 +1259,12 @@ export default { } printLogisticLabel([row],label.defaultPrinterName,this.printTest) } - this.printTest = false if (notFound.length > 0){ this.$message.warning(`The printer ${notFound.join(',')} is not found`) return } } + this.printTest = false this.$message.success(data.msg) }else { this.$message.warning(data.msg)