diff --git a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue index 768fbedec..63001d7b6 100644 --- a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue +++ b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue @@ -140,39 +140,46 @@ const buttonTableClick = async (val, row) => { } const BASE_URL = getJmreportBaseUrl() +const documentSrc = ref(BASE_URL + '/jmreport/view/1016234988731322368?token=' + getAccessToken()) const labelType = ref('') // 标签类别 采购还是制造等 // 标签打印 const handlePoint = async (row) => { // 查询是否已创建过标签 - await PackageApi.getPackagePage({ - requestNumber: row.number, - pageSize: 500, - pageNo: 1 - }).then((res) => { - if(res.list.length > 0) { - if (res.list[0].productionLineCode != null) { - labelType.value = 'zz' - } else { - labelType.value = 'cg' - } - PackageApi.batchPrintingLable(res.list.map(item1=>item1.number).join(',')).then((resLable) =>{ - console.log(159,resLable ) - - // 判断是采购还是制造 - if (labelType.value == 'cg') { - // const src = ref(BASE_URL + '/jmreport/view/922729953438072832?token=' + getAccessToken()) - const src = ref(BASE_URL + '/jmreport/view/998431235767558144?token=' + getAccessToken()) - window.open(src.value+'&asn_number='+resLable) - } else { - // const src = ref(BASE_URL + '/jmreport/view/922734157577715712?token=' + getAccessToken()) - const src = ref(BASE_URL + '/jmreport/view/998438158579556352?token=' + getAccessToken()) - window.open(src.value+'&asn_number='+resLable) - } - }) - } - }).catch(err => { - console.log(err) - }) + // await PackageApi.getPackagePage({ + // requestNumber: row.number, + // pageSize: 500, + // pageNo: 1 + // }).then((res) => { + // if(res.list.length > 0) { + // if (res.list[0].productionLineCode != null) { + // labelType.value = 'zz' + // } else { + // labelType.value = 'cg' + // } + // PackageApi.batchPrintingLable(res.list.map(item1=>item1.number).join(',')).then((resLable) =>{ + // console.log(159,resLable ) + + // // 判断是采购还是制造 + // if (labelType.value == 'cg') { + // // const src = ref(BASE_URL + '/jmreport/view/922729953438072832?token=' + getAccessToken()) + // const src = ref(BASE_URL + '/jmreport/view/998431235767558144?token=' + getAccessToken()) + // window.open(src.value+'&asn_number='+resLable) + // } else { + // // const src = ref(BASE_URL + '/jmreport/view/922734157577715712?token=' + getAccessToken()) + // const src = ref(BASE_URL + '/jmreport/view/998438158579556352?token=' + getAccessToken()) + // window.open(src.value+'&asn_number='+resLable) + // } + // }) + // } + // }).catch(err => { + // console.log(err) + // }) + if (row.itemType == 'TOOL') { + documentSrc.value =BASE_URL + '/jmreport/view/1028102732077142016?token=' + getAccessToken()//采购标签协定品模板 + } else { + documentSrc.value = BASE_URL + '/jmreport/view/1016234988731322368?token=' + getAccessToken()//采购标签模板 + } + window.open(documentSrc.value + '&request_number=' + row.number) } /** 详情操作 */