Browse Source

修改上架任务

hella_online_20240829
niexiting 6 months ago
parent
commit
42a45d5abf
  1. 13
      src/mycomponents/scan/winScanPackAndLocation.vue
  2. 31
      src/pages/putaway/job/putawayDetail.vue

13
src/mycomponents/scan/winScanPackAndLocation.vue

@ -120,7 +120,7 @@
inventoryStatus: [], inventoryStatus: [],
managementPrecision: '', managementPrecision: '',
fromInventoryStatuses: "", fromInventoryStatuses: "",
isCheck:false isCheck: false
} }
}, },
created() { created() {
@ -180,9 +180,9 @@
return; return;
} }
if(this.fromLocationList.length>0){ if (this.fromLocationList.length > 0) {
if(!this.isInLocationList(this.fromLocationCode)){ if (!this.isInLocationList(this.fromLocationCode)) {
this.showErrorMessage("扫描库位【"+this.fromLocationCode+'】不在任务来源库位中', callback => { this.showErrorMessage("扫描库位【" + this.fromLocationCode + '】不在任务来源库位中', callback => {
this.locationGetFocus(); this.locationGetFocus();
}) })
return; return;
@ -228,7 +228,7 @@
}) })
}, },
getScanResult(result) { getScanResult(result) {
// console.log("", result) // console.log("", result)
// if (this.fromLocationCode == '' || this.fromLocationCode == null) { // if (this.fromLocationCode == '' || this.fromLocationCode == null) {
// this.showMessage('', callback => { // this.showMessage('', callback => {
@ -243,7 +243,7 @@
// } // }
}, },
checkPackage(result){ checkPackage(result) {
if (result.label != null) { if (result.label != null) {
this.scanResult = result; this.scanResult = result;
// uni.showLoading({ // uni.showLoading({
@ -342,6 +342,7 @@
fromLocationCode: this.fromLocationCode, fromLocationCode: this.fromLocationCode,
} }
this.packGetFocus(); this.packGetFocus();
this.$emit("getResult", data);
this.$emit("getCountScanResult", data); this.$emit("getCountScanResult", data);
}, },

31
src/pages/putaway/job/putawayDetail.vue

@ -38,8 +38,11 @@
</view> </view>
<win-scan-button @goScan='openScanPopup'></win-scan-button> <win-scan-button @goScan='openScanPopup'></win-scan-button>
<winScanPackAndLocationNoBalance ref="scanPopup" @getResult='getScanResult' :allowNullBalance="true"> <!-- <winScanPackAndLocationNoBalance ref="scanPopup" @getResult='getScanResult' :allowNullBalance="true">
</winScanPackAndLocationNoBalance> </winScanPackAndLocationNoBalance> -->
<winScanPackAndLocation ref="scanPopup" @getResult='getScanResult' :noShowBalanceMessage="true">
</winScanPackAndLocation>
<comMessage ref="comMessage"></comMessage> <comMessage ref="comMessage"></comMessage>
</view> </view>
@ -80,7 +83,7 @@
} from '@/common/detail.js'; } from '@/common/detail.js';
import winScanButton from '@/mycomponents/scan/winScanButton.vue' 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 comJobDetailCard from "@/mycomponents/detail/comJobDetailCard.vue"
import locationCompare from '@/mycomponents/location/locationCompare.vue' import locationCompare from '@/mycomponents/location/locationCompare.vue'
import jobTop from '@/mycomponents/job/jobTop.vue' import jobTop from '@/mycomponents/job/jobTop.vue'
@ -89,7 +92,7 @@
export default { export default {
components: { components: {
winScanButton, winScanButton,
winScanPackAndLocationNoBalance, winScanPackAndLocation,
locationCompare, locationCompare,
comJobDetailCard, comJobDetailCard,
jobTop jobTop
@ -108,7 +111,7 @@
jobStatus: "", jobStatus: "",
jobToLocationCode: "", jobToLocationCode: "",
isCheckLocation: false, isCheckLocation: false,
scanedPackingNumber : '' scanedPackingNumber: ''
}; };
}, },
onLoad(option) { onLoad(option) {
@ -190,8 +193,9 @@
that.detailSource.forEach(r => { that.detailSource.forEach(r => {
r.subList.forEach(s => { r.subList.forEach(s => {
if(this.scanedPackingNumber&&this.scanedPackingNumber==s.packingNumber) s.scaned = true if (this.scanedPackingNumber && this.scanedPackingNumber == s
s.inventoryStatus = s.inspectResult;// .packingNumber) s.scaned = true
s.inventoryStatus = s.inspectResult; //
}) })
}) })
@ -282,6 +286,7 @@
var qty = result.label.qty; var qty = result.label.qty;
var itemCode = result.label.itemCode; var itemCode = result.label.itemCode;
var locationCode = result.fromLocationCode; var locationCode = result.fromLocationCode;
// var inventoryStatus = "OK"; // var inventoryStatus = "OK";
var detail = this.detailSource.find(r => r.itemCode == itemCode); var detail = this.detailSource.find(r => r.itemCode == itemCode);
@ -320,6 +325,13 @@
this.showMessage("箱码【" + packingNumber + "】已经扫描") this.showMessage("箱码【" + packingNumber + "】已经扫描")
} else { } else {
isExit.scaned = true 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.handleQty = Number(result.label.qty);
isExit.toLocationCode = this.toLocationCode; isExit.toLocationCode = this.toLocationCode;
} }
@ -475,6 +487,11 @@
detail.produceDate = getCurrDateTime(); detail.produceDate = getCurrDateTime();
detail.expireDate = getCurrDateTime(); detail.expireDate = getCurrDateTime();
let packList = detail.packList.filter(p => p.scaned == true);
detail.packList = packList;
// detail.singlePrice = detail.balance.singlePrice; // detail.singlePrice = detail.balance.singlePrice;
// detail.amount = detail.balance.singlePrice * detail.handleQty; // detail.amount = detail.balance.singlePrice * detail.handleQty;

Loading…
Cancel
Save