Browse Source

补给品标签

intex_online20241216
张立 2 months ago
parent
commit
25082bc61f
  1. 2
      src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue
  2. 20
      src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue

2
src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue

@ -1062,7 +1062,7 @@ const labelPrint = async (row) => {
// labelPrint(row)
await UnplannedreceiptRequestDetailApi.getDetailList(row.masterId).then(async (res) => {
if (res.length > 0) {
const itemType = res.some((item) => item.itemType == '可采购' && item.itemBasicType =='TOOL')//
const itemType = res.some((item) => item.itemType == '可采购' && item.itemBasicType =='TOOL')//
const itemType2 = res.some((item) => item.itemType == '可采购' && item.itemBasicType !='TOOL')
const itemType1 = res.some((item) => item.itemType == '可制造')
if (itemType) {

20
src/views/wms/productionManage/productreceipt/productreceiptRequestMain/index.vue

@ -979,14 +979,18 @@ const searchTableSuccessLabel = async (formField, searchField, val, formRef, typ
return
}
// window.open(src.value + '&asn_number=' + val.map(item1=>item1.number).join(','))
let array = []//
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)
@ -1000,6 +1004,16 @@ let array = []//存储可采购数据
console.log(err)
message.error('创建标签失败')
})
}
//
if (arrayTool.length>0) {
await PackageApi.getPrintingLableId({packingNumbers:arrayTool.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 => {

Loading…
Cancel
Save