|
@ -489,15 +489,21 @@ |
|
|
let _this = this |
|
|
let _this = this |
|
|
batchPrintingLable(number).then(resLable => { |
|
|
batchPrintingLable(number).then(resLable => { |
|
|
console.log('batchPrintingLable', resLable) |
|
|
console.log('batchPrintingLable', resLable) |
|
|
const webUrl = `${import.meta.env.VITE_JMREPORT_BASE_URL}/jmreport/view/922734157577715712` |
|
|
uni.hideLoading() |
|
|
const webData = { |
|
|
if(resLable.data){ |
|
|
token: storage.getStorage(storage.constant.token), |
|
|
const webUrl = `${import.meta.env.VITE_JMREPORT_BASE_URL}/jmreport/view/922734157577715712` |
|
|
asn_number: resLable.data |
|
|
const webData = { |
|
|
|
|
|
token: storage.getStorage(storage.constant.token), |
|
|
|
|
|
asn_number: resLable.data |
|
|
|
|
|
} |
|
|
|
|
|
uni.navigateTo({ |
|
|
|
|
|
url: `/pages/pointProductReceipt/webview?url=${webUrl}&webData=${JSON.stringify(webData)}` |
|
|
|
|
|
}); |
|
|
|
|
|
}else { |
|
|
|
|
|
_this.showErrorMessage(number+"批量打印标签 H5失败") |
|
|
} |
|
|
} |
|
|
uni.navigateTo({ |
|
|
|
|
|
url: `/pages/pointProductReceipt/webview?url=${webUrl}&webData=${JSON.stringify(webData)}` |
|
|
|
|
|
}); |
|
|
|
|
|
}).catch(error => { |
|
|
}).catch(error => { |
|
|
|
|
|
uni.hideLoading() |
|
|
_this.showErrorMessage(error) |
|
|
_this.showErrorMessage(error) |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
@ -520,13 +526,28 @@ |
|
|
_this.showErrorMessage('包装号不能为空!') |
|
|
_this.showErrorMessage('包装号不能为空!') |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
|
|
|
uni.showLoading({ |
|
|
|
|
|
title:"正在获取打印信息", |
|
|
|
|
|
mask:true |
|
|
|
|
|
}) |
|
|
getBalanceToPackage({ |
|
|
getBalanceToPackage({ |
|
|
packingNumber: packingNumber.join(',') |
|
|
packingNumber: packingNumber.join(',') |
|
|
}).then(res => { |
|
|
}).then(res => { |
|
|
console.log('PC打印', res) |
|
|
console.log('PC打印', res) |
|
|
_this.getH5BatchPrintingLable(res.data.number) |
|
|
if(res.data&&res.data.number){ |
|
|
|
|
|
_this.getH5BatchPrintingLable(res.data.number) |
|
|
|
|
|
}else { |
|
|
|
|
|
uni.hideLoading() |
|
|
|
|
|
var hint ="" |
|
|
|
|
|
packingNumber.forEach(item=>{ |
|
|
|
|
|
hint+=item |
|
|
|
|
|
}) |
|
|
|
|
|
hint+"根据库存余额获取包装信息" |
|
|
|
|
|
_this.showErrorMessage(hint) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
}).catch(error => { |
|
|
}).catch(error => { |
|
|
|
|
|
uni.hideLoading() |
|
|
_this.showErrorMessage(error) |
|
|
_this.showErrorMessage(error) |
|
|
}) |
|
|
}) |
|
|
// #endif |
|
|
// #endif |
|
|