|
|
@ -50,9 +50,9 @@ |
|
|
|
<view class="uni-flex u-col-center space-between padding_10" |
|
|
|
style="background-color:ghostwhite; width: 100%; "> |
|
|
|
<view class=""> |
|
|
|
<locationCompare title="收货库位" :isShowEdit="jobContent.allowModifyLocation=='TRUE'" :recommendLocationCode="jobToLocationCode" |
|
|
|
:locationCode="toLocationCode" @getLocation='scanLocationCode' |
|
|
|
:locationTypeList="toLocationTypeList"></locationCompare> |
|
|
|
<locationCompare title="收货库位" :isShowEdit="jobContent.allowModifyLocation=='TRUE'" |
|
|
|
:recommendLocationCode="jobToLocationCode" :locationCode="toLocationCode" |
|
|
|
@getLocation='scanLocationCode' :locationTypeList="toLocationTypeList"></locationCompare> |
|
|
|
</view> |
|
|
|
<view class=" uni-flex uni-row"> |
|
|
|
<button class="btn_single_commit" hover-class="btn_commit_after" @click="commit">提交</button> |
|
|
@ -76,7 +76,9 @@ |
|
|
|
takeProductReceiptJob, |
|
|
|
cancleTakeProductReceiptJob, |
|
|
|
productReceiptJobsubmit, |
|
|
|
getPrintProductReceiptList |
|
|
|
getPrintProductReceiptList, |
|
|
|
getBalanceToPackage, |
|
|
|
batchPrintingLable |
|
|
|
} from '@/api/request2.js'; |
|
|
|
import { |
|
|
|
goHome, |
|
|
@ -290,7 +292,7 @@ |
|
|
|
} |
|
|
|
}) |
|
|
|
// 扫满箱后应该自动提交 |
|
|
|
if(pack.scaned&&pack.qty==pack.fgList.length){ |
|
|
|
if (pack.scaned && pack.qty == pack.fgList.length) { |
|
|
|
this.commit() |
|
|
|
} |
|
|
|
}) |
|
|
@ -342,13 +344,14 @@ |
|
|
|
}, |
|
|
|
//打印功能 |
|
|
|
print() { |
|
|
|
let _this = this |
|
|
|
let packingNumber = [] |
|
|
|
this.detailSource.forEach(item => { |
|
|
|
item.subList.forEach(detail => { |
|
|
|
if (detail.scaned) { |
|
|
|
// var info = getPackingNumberAndBatch(this.managementList, detail.itemCode, |
|
|
|
// detail.packingNumber, detail.batch); |
|
|
|
// detail.toPackingNumber = info.packingNumber; |
|
|
|
// var info = getPackingNumberAndBatch(this.managementList, detail.itemCode, |
|
|
|
// detail.packingNumber, detail.batch); |
|
|
|
// detail.toPackingNumber = info.packingNumber; |
|
|
|
packingNumber.push(detail.packingNumber) |
|
|
|
} |
|
|
|
}) |
|
|
@ -381,19 +384,38 @@ |
|
|
|
}); |
|
|
|
|
|
|
|
}).catch(error => { |
|
|
|
this.showErrorMessage(error) |
|
|
|
_this.showErrorMessage(error) |
|
|
|
}) |
|
|
|
// #endif |
|
|
|
// #ifdef H5 |
|
|
|
const webUrl = |
|
|
|
`${import.meta.env.VITE_JMREPORT_BASE_URL}/jmreport/view/922734157577715712?token=${storage.getStorage(storage.constant.token)}&asn_number=${packingNumber.join(',')}` |
|
|
|
uni.navigateTo({ |
|
|
|
url: `/pages/pointProductReceipt/webview?url=${webUrl}` |
|
|
|
}); |
|
|
|
getBalanceToPackage({ |
|
|
|
packingNumber: packingNumber.join(',') |
|
|
|
}).then(res => { |
|
|
|
console.log('PC打印', res) |
|
|
|
_this.getH5BatchPrintingLable(res.data.number) |
|
|
|
|
|
|
|
}).catch(error => { |
|
|
|
_this.showErrorMessage(error) |
|
|
|
}) |
|
|
|
|
|
|
|
// #endif |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
getH5BatchPrintingLable( number) { |
|
|
|
let _this = this |
|
|
|
batchPrintingLable(number).then(resLable => { |
|
|
|
console.log('batchPrintingLable', resLable) |
|
|
|
const webUrl = `${import.meta.env.VITE_JMREPORT_BASE_URL}/jmreport/view/922734157577715712` |
|
|
|
const webData = { |
|
|
|
token: storage.getStorage(storage.constant.token), |
|
|
|
asn_number: resLable.data |
|
|
|
} |
|
|
|
uni.navigateTo({ |
|
|
|
url: `/pages/pointProductReceipt/webview?url=${webUrl}&webData=${JSON.stringify(webData)}` |
|
|
|
}); |
|
|
|
}) |
|
|
|
}, |
|
|
|
commit() { |
|
|
|
// this.scanCount = getScanCount(this.subList); |
|
|
|
// if (this.scanCount == 0) { |
|
|
|