diff --git a/src/views/plan/workorder/index.vue b/src/views/plan/workorder/index.vue index 7b140cb..c1abe9a 100644 --- a/src/views/plan/workorder/index.vue +++ b/src/views/plan/workorder/index.vue @@ -1838,7 +1838,7 @@ export default { this.$modal.msgError("还未派发请到工单变更进行调整!"); return; } - + this.batchLoading = true; const workOrdercode = this.codes[0]; @@ -1987,10 +1987,17 @@ export default { /**打印标识卡弹出框**/ printIdCard() { - this.$refs.printID.init("20021221552"); - this.$refs.printID.showPrint(); + + //var statusesArray = this.statuses; + //for (var i = 0; i < statusesArray.length; i++) { + // if (statusesArray[i] != 'w0') {//已经下达的不允许操作 + // this.$modal.msgError("工单只有未派发和已派发才可变更!"); + // return + // } + //} + + this.$refs.printID.init(this.selectWork.workorderCode); this.$refs.printID.printDialogVisible = true; - }, //标识卡选择确认 printIdFunc(obj) { diff --git a/src/views/plan/workorder/printID.vue b/src/views/plan/workorder/printID.vue index 3abe6e6..cd0f695 100644 --- a/src/views/plan/workorder/printID.vue +++ b/src/views/plan/workorder/printID.vue @@ -16,11 +16,11 @@ -
产品名称: {{ printData.factory }}

-
批次号: {{ printData.factory }}

-
生产日期: {{ printData.factory }}

-
板次: {{ printData.factory }}

-
数量: {{ printData.factory }}
+
产品名称: {{ item.productName }}

+
批次号: {{ item.batchCode }}

+
生产日期: {{ item.productDateStr }}

+
板次: {{ item.PalletNo }}

+
数量: {{ item.batchQuantity }}
@@ -89,12 +89,13 @@ export default { created() { }, mounted() { - //this.showPrint(); + }, methods: { init(workorderCode){ this.workorderCode = workorderCode; + this.showPrint(); }, // 打印预览-浏览器打印 @@ -115,13 +116,12 @@ export default { }, // 打印预览-点击打印预览按钮 async showPrint() { - console.log('执行了打印预览'); - let response = await getIdCardList(this.workorderCode,this.idCardNum); - this.printData.idCardList = response.idCards; + let response = await getIdCardList(this.workorderCode); + this.printData.idCardList = response; this.$nextTick(() => { this.printData.idCardList.forEach((item, index) => { const canvas = document.getElementById('qrcode-' + index); - QRCode.toCanvas(canvas, item, { width: 350,margin:1 }, function (error) { + QRCode.toCanvas(canvas, item.palletCode, { width: 350,margin:1 }, function (error) { if (error) console.error(error); console.log('success!'); }); diff --git a/src/views/wms/product/index.vue b/src/views/wms/product/index.vue index f93ae87..234985d 100644 --- a/src/views/wms/product/index.vue +++ b/src/views/wms/product/index.vue @@ -384,6 +384,11 @@ style="width: 320px" /> + + + + + - - -