diff --git a/src/mycomponents/scan/winScanPackAndLocation.vue b/src/mycomponents/scan/winScanPackAndLocation.vue
index 1e6b5283..8996b173 100644
--- a/src/mycomponents/scan/winScanPackAndLocation.vue
+++ b/src/mycomponents/scan/winScanPackAndLocation.vue
@@ -120,7 +120,7 @@
inventoryStatus: [],
managementPrecision: '',
fromInventoryStatuses: "",
- isCheck:false
+ isCheck: false
}
},
created() {
@@ -179,10 +179,10 @@
})
return;
}
-
- if(this.fromLocationList.length>0){
- if(!this.isInLocationList(this.fromLocationCode)){
- this.showErrorMessage("扫描库位【"+this.fromLocationCode+'】不在任务来源库位中', callback => {
+
+ if (this.fromLocationList.length > 0) {
+ if (!this.isInLocationList(this.fromLocationCode)) {
+ this.showErrorMessage("扫描库位【" + this.fromLocationCode + '】不在任务来源库位中', callback => {
this.locationGetFocus();
})
return;
@@ -228,7 +228,7 @@
})
},
- getScanResult(result) {
+ getScanResult(result) {
// console.log("扫描", result)
// if (this.fromLocationCode == '' || this.fromLocationCode == null) {
// this.showMessage('请先扫描来源库位', callback => {
@@ -242,8 +242,8 @@
// this.checkPackage(result);
// }
},
-
- checkPackage(result){
+
+ checkPackage(result) {
if (result.label != null) {
this.scanResult = result;
// uni.showLoading({
@@ -342,6 +342,7 @@
fromLocationCode: this.fromLocationCode,
}
this.packGetFocus();
+ this.$emit("getResult", data);
this.$emit("getCountScanResult", data);
},
@@ -424,9 +425,9 @@
this.show = e.show
},
isInLocationList(location) {
-
+
var item = this.fromLocationList.find(res => res == location)
-
+
if (item = undefined) {
return false
}
@@ -447,4 +448,4 @@
height: auto;
max-height: 300rpx;
}
-
+
\ No newline at end of file
diff --git a/src/pages/putaway/job/putawayDetail.vue b/src/pages/putaway/job/putawayDetail.vue
index 86e7a61d..64db0566 100644
--- a/src/pages/putaway/job/putawayDetail.vue
+++ b/src/pages/putaway/job/putawayDetail.vue
@@ -38,8 +38,11 @@
-
-
+
+
+
+
@@ -80,7 +83,7 @@
} from '@/common/detail.js';
import winScanButton from '@/mycomponents/scan/winScanButton.vue'
- import winScanPackAndLocationNoBalance from "@/mycomponents/scan/winScanPackAndLocationNoBalance.vue"
+ import winScanPackAndLocation from "@/mycomponents/scan/winScanPackAndLocation.vue"
import comJobDetailCard from "@/mycomponents/detail/comJobDetailCard.vue"
import locationCompare from '@/mycomponents/location/locationCompare.vue'
import jobTop from '@/mycomponents/job/jobTop.vue'
@@ -89,7 +92,7 @@
export default {
components: {
winScanButton,
- winScanPackAndLocationNoBalance,
+ winScanPackAndLocation,
locationCompare,
comJobDetailCard,
jobTop
@@ -108,7 +111,7 @@
jobStatus: "",
jobToLocationCode: "",
isCheckLocation: false,
- scanedPackingNumber : ''
+ scanedPackingNumber: ''
};
},
onLoad(option) {
@@ -190,8 +193,9 @@
that.detailSource.forEach(r => {
r.subList.forEach(s => {
- if(this.scanedPackingNumber&&this.scanedPackingNumber==s.packingNumber) s.scaned = true
- s.inventoryStatus = s.inspectResult;//更新检验结果状态
+ if (this.scanedPackingNumber && this.scanedPackingNumber == s
+ .packingNumber) s.scaned = true
+ s.inventoryStatus = s.inspectResult; //更新检验结果状态
})
})
@@ -282,6 +286,7 @@
var qty = result.label.qty;
var itemCode = result.label.itemCode;
var locationCode = result.fromLocationCode;
+
// var inventoryStatus = "OK";
var detail = this.detailSource.find(r => r.itemCode == itemCode);
@@ -320,6 +325,13 @@
this.showMessage("箱码【" + packingNumber + "】已经扫描")
} else {
isExit.scaned = true
+ let qty = 0;
+ if (result.balance != null) {
+ qty = Number(result.balance.qty);
+ } else {
+ qty = Number(result.label.qty);
+ }
+
isExit.handleQty = Number(result.label.qty);
isExit.toLocationCode = this.toLocationCode;
}
@@ -475,6 +487,11 @@
detail.produceDate = getCurrDateTime();
detail.expireDate = getCurrDateTime();
+
+ let packList = detail.packList.filter(p => p.scaned == true);
+ detail.packList = packList;
+
+
// detail.singlePrice = detail.balance.singlePrice;
// detail.amount = detail.balance.singlePrice * detail.handleQty;