From 6c5242adea68d9bb34423ab0747123333c0e3925 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Sun, 15 Dec 2024 12:07:51 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=9F=E4=BA=A7=E9=80=80=E6=96=99=E6=89=93?= =?UTF-8?q?=E5=8D=B0=E6=A0=87=E7=AD=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../productionreturnRequestMain/index.vue | 20 ++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue b/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue index ffe2c8c6f..eecbfbbe2 100644 --- a/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue +++ b/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/index.vue @@ -708,18 +708,26 @@ const searchTableSuccess1 = async (formField, searchField, val, formRef, type, r try { // window.open(src.value + '&asn_number=' + val.map(item1=>item1.number).join(',')) let array = []//存储可采购数据 + let arrayTool = []//存储可采购协定品数据 let array1 = []//存储可制造数据 let packingNumbers = [] val.forEach((item,index) => { packingNumbers.push(item.number) if (item.itemType == '可采购') { - array.push(item) + if (item.itemBasicType =='TOOL') { + arrayTool.push(item) + } else { + array.push(item) + } } if (item.itemType == '可制造') { array1.push(item) } }) + console.log(arrayTool) + console.log(array) + // 打印采购件 if (array.length>0) { await PackageApi.getPrintingLableId({packingNumbers:array.map(item1=>item1.number)}).then(res => { console.log(res) @@ -729,6 +737,16 @@ const searchTableSuccess1 = async (formField, searchField, val, formRef, type, r message.error('创建标签失败') }) } + // 打印协定品采购件 + if (arrayTool.length>0) { + await PackageApi.getPrintingLableId({packingNumbers:array.map(item1=>item1.number)}).then(res => { + console.log(res) + window.open(BASE_URL + '/jmreport/view/1028102732077142016?token=' + getAccessToken()+'&id=' + res) + }).catch(err => { + console.log(err) + message.error('创建标签失败') + }) + } if (array1.length > 0) { await PackageApi.batchPrintingLable(array1.map(item1=>item1.number).join(',')).then(res => { console.log(res)