|
|
@ -14,9 +14,9 @@ |
|
|
|
@change="switchChange"></u-switch> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="" v-if ="operation=='reject'"> |
|
|
|
<view class="" v-if="operation=='reject'"> |
|
|
|
<uni-section title="拒收原因" type="line"> |
|
|
|
<uni-easyinput v-model="reasonText" placeholder="请输入拒收原因" ></uni-easyinput> |
|
|
|
<uni-easyinput v-model="reasonText" placeholder="请输入拒收原因"></uni-easyinput> |
|
|
|
</uni-section> |
|
|
|
|
|
|
|
</view> |
|
|
@ -44,8 +44,7 @@ |
|
|
|
<view v-if="operation=='receipt'" class="uni-flex u-col-center space-between padding_10"> |
|
|
|
<view> |
|
|
|
<locationCompare ref="locationCompare" title="收货库位" :recommendLocationCode="jobToLocationCode" |
|
|
|
@getLocation='scanLocationCode' |
|
|
|
:locationAreaTypeList="toLocationAreaTypeList"> |
|
|
|
@getLocation='scanLocationCode' :locationAreaTypeList="toLocationAreaTypeList"> |
|
|
|
</locationCompare> |
|
|
|
</view> |
|
|
|
<view> |
|
|
@ -143,8 +142,8 @@ |
|
|
|
operation: '', |
|
|
|
scanMessage: '', |
|
|
|
status: '', |
|
|
|
switchCode:"", |
|
|
|
isCheckLocation: 'purchaseReceiptLocationCodeValidate',//校验收货库位 |
|
|
|
switchCode: "", |
|
|
|
isCheckLocation: 'purchaseReceiptLocationCodeValidate', //校验收货库位 |
|
|
|
reasonText: "", |
|
|
|
}; |
|
|
|
}, |
|
|
@ -155,7 +154,7 @@ |
|
|
|
this.scanMessage = option.scanMessage; |
|
|
|
this.operation = option.operation; |
|
|
|
this.status = option.status; |
|
|
|
this.switchCode = "purchasereceiptPrintPDA"//pda打印 |
|
|
|
this.switchCode = "purchasereceiptPrintPDA" //pda打印 |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
@ -249,10 +248,10 @@ |
|
|
|
} |
|
|
|
that.isAllReceived = false; |
|
|
|
//如果箱码扫描自动扫描,ASN不自动扫描 |
|
|
|
if(this.scanMessage){ |
|
|
|
if (this.scanMessage) { |
|
|
|
this.$refs.scanPopup.simulateScan(this.scanMessage); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} else { |
|
|
|
that.showMessage('列表数据为0'); |
|
|
|
} |
|
|
@ -265,7 +264,6 @@ |
|
|
|
|
|
|
|
|
|
|
|
getScanResult(result) { |
|
|
|
|
|
|
|
try { |
|
|
|
var itemCode = result.label.itemCode; |
|
|
|
var detail = this.detailSource.find(r => r.itemCode == itemCode); |
|
|
@ -284,10 +282,11 @@ |
|
|
|
} else { |
|
|
|
itemDetail.forEach(item => { |
|
|
|
item.scaned = true; |
|
|
|
itemDetail.scaneDate = new Date(); |
|
|
|
item.handleQty = item.qty; |
|
|
|
item.toLocationCode = this.toLocationCode; |
|
|
|
}) |
|
|
|
this.detailSource[0].subList.sort(compareAsc('scaned')); //按扫描信息排序 |
|
|
|
this.detailSource[0].subList.sort(compareAsc('scaneDate')); //按扫描信息排序 |
|
|
|
calcHandleQty(this.detailSource); |
|
|
|
this.continueScan() |
|
|
|
this.$forceUpdate() |
|
|
@ -306,9 +305,13 @@ |
|
|
|
batch); |
|
|
|
if (itemDetail == undefined) { |
|
|
|
var isExit; |
|
|
|
for (let subItem of detail.subList) { |
|
|
|
let subItem; |
|
|
|
let index = -1; |
|
|
|
for (subItem of detail.subList) { |
|
|
|
var item; |
|
|
|
for (let pack of subItem.packList) { |
|
|
|
for (var i = 0; i < subItem.packList.length; i++) { |
|
|
|
let pack = subItem.packList[i]; |
|
|
|
index = i; |
|
|
|
if (pack.packingNumber == packingNumber && |
|
|
|
pack.batch == batch) { |
|
|
|
item = pack; |
|
|
@ -316,18 +319,26 @@ |
|
|
|
break; |
|
|
|
} |
|
|
|
} |
|
|
|
if (item != undefined) { |
|
|
|
subItem.scaned = true |
|
|
|
subItem.handleQty = 0; |
|
|
|
item = undefined |
|
|
|
} |
|
|
|
// for (let pack of subItem.packList) { |
|
|
|
// if (pack.packingNumber == packingNumber && |
|
|
|
// pack.batch == batch) { |
|
|
|
// item = pack; |
|
|
|
// isExit = pack; |
|
|
|
// break; |
|
|
|
// } |
|
|
|
// } |
|
|
|
// if (item != undefined) { |
|
|
|
// subItem.scaned = true |
|
|
|
// subItem.handleQty = 0; |
|
|
|
// item = undefined |
|
|
|
// } |
|
|
|
} |
|
|
|
|
|
|
|
if (isExit == undefined) { |
|
|
|
this.showMessage("箱码【" + packingNumber + "】、批次【" + batch + "】不在列表中") |
|
|
|
} else { |
|
|
|
if ( isExit.scaned) { |
|
|
|
this.showMessage("箱码【" + packingNumber + "】已经扫描") |
|
|
|
if (isExit.scaned) { |
|
|
|
this.showMessage("箱码【" + packingNumber + "】已经扫描"); |
|
|
|
} else { |
|
|
|
isExit.scaned = true |
|
|
|
isExit.handleQty = Number(result.label.qty); |
|
|
@ -349,12 +360,14 @@ |
|
|
|
this.showMessage("箱码【" + packingNumber + "】已经扫描") |
|
|
|
} else { |
|
|
|
itemDetail.scaned = true; |
|
|
|
this.detailSource[0].subList.sort(compareAsc('scaned')); //按扫描信息排序 |
|
|
|
itemDetail.scaneDate = new Date(); |
|
|
|
this.detailSource[0].subList.sort(compareAsc('scaneDate')); //按扫描信息排序 |
|
|
|
itemDetail.handleQty = Number(result.label.qty); |
|
|
|
itemDetail.toLocationCode = this.toLocationCode; |
|
|
|
itemDetail.labelQty = Number(result.label.qty); |
|
|
|
itemDetail.packList.forEach(pac => { |
|
|
|
pac.scaned = true |
|
|
|
itemDetail.scaneDate = new Date(); |
|
|
|
pac.handleQty = Number(pac.qty); |
|
|
|
pac.toLocationCode = this.toLocationCode; |
|
|
|
}) |
|
|
@ -445,7 +458,7 @@ |
|
|
|
}, |
|
|
|
|
|
|
|
reject() { |
|
|
|
if(!this.reasonText){ |
|
|
|
if (!this.reasonText) { |
|
|
|
this.showMessage("请输入拒收原因") |
|
|
|
return; |
|
|
|
} |
|
|
|