From 27fd58c27aa30b1571159bca31f4cb2be56178c8 Mon Sep 17 00:00:00 2001
From: zhang_li <2235006734@qqq.com>
Date: Wed, 6 Nov 2024 17:30:29 +0800
Subject: [PATCH] =?UTF-8?q?=E7=9B=B4=E6=8E=A5=E5=90=88=E6=A0=BC=E8=BD=AC?=
=?UTF-8?q?=E9=9A=94=E7=A6=BB?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../scan/winScanPackAndLocation.vue | 3 +
.../inventoryMove/coms/comMoveRecord.vue | 79 +++----------------
.../inventoryMove/coms/okToHoldRecordPack.vue | 15 ++--
3 files changed, 23 insertions(+), 74 deletions(-)
diff --git a/src/mycomponents/scan/winScanPackAndLocation.vue b/src/mycomponents/scan/winScanPackAndLocation.vue
index aaebd305..43b14388 100644
--- a/src/mycomponents/scan/winScanPackAndLocation.vue
+++ b/src/mycomponents/scan/winScanPackAndLocation.vue
@@ -236,6 +236,9 @@
scanLocation(scanResult) {
+ if(scanResult.fromLocationCode){
+ this.fromLocationCode = scanResult.fromLocationCode
+ }
var isCheck = false;
if (this.fromLocationCode == '') {
this.showErrorMessage('来源库位不能为空', callback => {
diff --git a/src/pages/inventoryMove/coms/comMoveRecord.vue b/src/pages/inventoryMove/coms/comMoveRecord.vue
index 49af4c40..bf25e86c 100644
--- a/src/pages/inventoryMove/coms/comMoveRecord.vue
+++ b/src/pages/inventoryMove/coms/comMoveRecord.vue
@@ -35,7 +35,7 @@
-
+
{
if (r.batch == pack.batch &&
r.fromLocationCode == balance.locationCode &&
@@ -393,68 +396,6 @@
return r;
}
})
-
- if (detail == undefined) {
- let newDetail = createDetailInfo(balance, pack);
- // newDetail.inventoryStatus = balance.inventoryStatus;
- if (this.businessTypeCode == "Move") {
- newDetail.toInventoryStatus = balance.inventoryStatus;
- } else {
- newDetail.toInventoryStatus = this.toInventoryStatus;
- }
-
- if (newDetail.packingNumber == '') {
- newDetail.packingNumber = pack.number;
- }
- newDetail.toLocationCode = this.toLocationCode;
- newDetail.fromLocationCode = result.fromLocationCode
- item.subList.push(newDetail);
- } else {
- detail.handleQty =calc.add(detail.handleQty, result.label.qty)
- }
- }
- calcHandleQty(this.detailSource);
- },
- getScanResultAfterBatchOnePop(result){
- var balance = result.balance;
- this.balanceInfo = result.balance;
- var pack = result.package;
- var item = this.detailSource.find(res => {
- if (res.itemCode == balance.itemCode) {
- return res
- }
- })
- if (item == undefined) {
- var itemp = createItemInfo(balance, pack);
- let newDetail = createDetailInfo(balance, pack);
-
- if (newDetail.packingNumber == '') {
- newDetail.packingNumber = pack.number;
- }
- if (this.businessTypeCode == "Move") {
- newDetail.toInventoryStatus = balance.inventoryStatus;
- } else {
- newDetail.toInventoryStatus = this.toInventoryStatus;
- }
- newDetail.toLocationCode = this.toLocationCode;
- newDetail.fromLocationCode = result.fromLocationCode
- itemp.subList.push(newDetail);
- this.detailSource.push(itemp)
- } else {
- if( balance.inventoryStatus != this.toInventoryStatus){
- this.showErrorMessage("库存状态的库存")
- return
- }
- var detail = item.subList.find(r => {
- if (r.batch == pack.batch &&
- r.fromLocationCode == balance.locationCode &&
- r.toInventoryStatus == balance.inventoryStatus &&
- r.scaned == true) {
- return r;
- }
- })
- console.log(2333,detail)
-
if (detail == undefined) {
let newDetail = createDetailInfo(balance, pack);
// newDetail.inventoryStatus = balance.inventoryStatus;
@@ -476,10 +417,14 @@
}
calcHandleQty(this.detailSource);
},
- fromLocationBlur(result){
+ getInputMsgResult(result){
console.log('pooo',result)
- this.$refs.scanFromLocationCode.getScanResult(result)
- // this.$refs.scanPopup.
+ if(!this.fromLocationCode){
+ this.$refs.scanFromLocationCode.getScanResult(result)
+ }else{
+ result.fromLocationCode = this.fromLocationCode
+ this.$refs.scanPopup.getScanResult(result)
+ }
},
showErrorMessage(message) {
if (this.$refs.scanPopup) {
diff --git a/src/pages/inventoryMove/coms/okToHoldRecordPack.vue b/src/pages/inventoryMove/coms/okToHoldRecordPack.vue
index 0f210073..3ddc1ce5 100644
--- a/src/pages/inventoryMove/coms/okToHoldRecordPack.vue
+++ b/src/pages/inventoryMove/coms/okToHoldRecordPack.vue
@@ -9,14 +9,14 @@
来源库位:
-
+
零件:
-
+
@@ -62,7 +62,7 @@
components: {
winScanLocation
},
- emits: ["showFromLocationPopup",'itemCodeClick','confirm','fromLocationBlur'],
+ emits: ["showFromLocationPopup",'itemCodeClick','confirm','getInputMsgResult'],
data() {
return {
show:true,
@@ -120,7 +120,7 @@
this.scanMsg = this.fromLocationCode
this.handelScanMsg()
},
- itemCodeBlur(){
+ itemCodeScanMsg(){
this.scanMsg = this.itemCode
this.handelScanMsg()
},
@@ -136,7 +136,7 @@
// that.scanMsg =that.scanMsg + "\n";
// }
console.log(that.scanMsg.includes('\n'))
- if (that.scanMsg.includes('\n')) {
+ // if (that.scanMsg.includes('\n')) {
// that.scanMsg = 'HPQ;V1.0;ICE115F11161AG;PP20230427000027;B20230427002;Q50';
setTimeout(() => {
that.losefocus();
@@ -162,7 +162,7 @@
scanResult.scanMessage = content
if (scanResult.success) {
// that.getfocus();//不能自动获取焦点
- that.$emit("fromLocationBlur", scanResult);
+ that.$emit("getInputMsgResult", scanResult);
} else {
that.losefocus();
this.$refs.comMessage.showErrorMessage(scanResult.message, res => {
@@ -173,7 +173,7 @@
}
});
}, 200);
- }
+ // }
},
losefocus() {
let that = this;
@@ -192,6 +192,7 @@
},
batchProps(newVal) {
this.batch = newVal
+ console.log(999,this.batch)
},
}
}