From e9a30bf29301b15b7a7772e1d8ab37c407e02757 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 7 Nov 2024 17:11:53 +0800 Subject: [PATCH 1/2] =?UTF-8?q?YT-765=E5=88=B6=E5=93=81=E7=9B=B4=E6=8E=A5?= =?UTF-8?q?=E6=94=B6=E8=B4=A7=EF=BC=8C=E8=BE=93=E5=85=A5=E4=B8=8D=E6=AD=A3?= =?UTF-8?q?=E7=A1=AE=E5=88=B6=E5=93=81=E6=A0=87=E7=AD=BE=EF=BC=8C=E6=B2=A1?= =?UTF-8?q?=E6=9C=89=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../productReceipt/record/productReceiptRecordByBatch.vue | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/pages/productReceipt/record/productReceiptRecordByBatch.vue b/src/pages/productReceipt/record/productReceiptRecordByBatch.vue index d12eabf4..c50e0cff 100644 --- a/src/pages/productReceipt/record/productReceiptRecordByBatch.vue +++ b/src/pages/productReceipt/record/productReceiptRecordByBatch.vue @@ -145,13 +145,17 @@ getScanResult(result) { let label = result.label; let pack = result.package; - + if(!result.label.itemCode){ + this.showErrorMessage('扫描标签不对,请重新扫描') + this.$emit('clearItemCode',result.label) + return + } var item = this.detailSource.find(res => { if (res.itemCode == label.itemCode) { return res } }) - + if (item == undefined) { var itemp = this.createItemInfo(label, pack); let newDetail = this.createDetailInfo(label, pack); From 72674ec5dab89a0a8505228fb4e7fa9bcafcf920 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 7 Nov 2024 17:13:27 +0800 Subject: [PATCH 2/2] =?UTF-8?q?YT-767pda=20=E7=9B=B4=E6=8E=A5=E7=A7=BB?= =?UTF-8?q?=E5=BA=93=EF=BC=8C=E5=BC=B9=E5=87=BA=E4=B8=A4=E4=B8=AA=E6=89=AB?= =?UTF-8?q?=E6=9D=A5=E8=BF=90=E5=BA=93=E4=BD=8D=20=20=E7=9B=B4=E6=8E=A5?= =?UTF-8?q?=E5=90=88=E6=A0=BC=E8=BD=AC=E9=9A=94=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/mycomponents/scan/winScanLocation.vue | 2 - .../scan/winScanPackAndLocation.vue | 3 +- .../inventoryMove/coms/comMoveRecord.vue | 40 +++++++++---------- .../inventoryMove/coms/okToHoldRecordPack.vue | 20 +++++----- 4 files changed, 33 insertions(+), 32 deletions(-) diff --git a/src/mycomponents/scan/winScanLocation.vue b/src/mycomponents/scan/winScanLocation.vue index a7f363c5..2d3d491f 100644 --- a/src/mycomponents/scan/winScanLocation.vue +++ b/src/mycomponents/scan/winScanLocation.vue @@ -92,7 +92,6 @@ title: '扫描中...', mask: true }); - console.log(111,result) let label = result.label; if (label.barType === 'QRCode') { this.code = label.locationCode; @@ -104,7 +103,6 @@ this.showErrorMessage("扫描库位为空,请输入正确的库位") return } - console.log(888,this.code) getBasicLocationByCode(this.code).then(res => { uni.hideLoading(); diff --git a/src/mycomponents/scan/winScanPackAndLocation.vue b/src/mycomponents/scan/winScanPackAndLocation.vue index 2ae6adda..7a25ef9e 100644 --- a/src/mycomponents/scan/winScanPackAndLocation.vue +++ b/src/mycomponents/scan/winScanPackAndLocation.vue @@ -339,7 +339,7 @@ this.chooseWhich = '2' if(!result.label.itemCode){ this.showErrorMessage('扫描标签不对,请重新扫描') - this.$emit('clearItemCode',result.label.code) + this.$emit('clearItemCode',result.label) return } if (res.data && res.data.list && res.data.list.length > 1) { @@ -397,6 +397,7 @@ mustHavaBalance(datas) { if (datas.length == 0) { this.showErrorMessage(this.getQueryCondition() + '\n未查找到库存记录', res => { + this.$emit('clearItemCode',this.scanResult) this.packGetFocus(); }) } else if (datas.length == 1) { diff --git a/src/pages/inventoryMove/coms/comMoveRecord.vue b/src/pages/inventoryMove/coms/comMoveRecord.vue index d4408686..e256104c 100644 --- a/src/pages/inventoryMove/coms/comMoveRecord.vue +++ b/src/pages/inventoryMove/coms/comMoveRecord.vue @@ -32,7 +32,7 @@ - + @@ -160,12 +160,7 @@ this.businessType = res.businessType; this.fromLocationAreaTypeList = res.fromLocationAreaTypeList; this.toLocationAreaTypeList = res.toLocationAreaTypeList; - if(this.showOnePop){ - console.log(this.$refs.okToHoldRecordPackRef) - this.$refs.okToHoldRecordPackRef.show = true - }else{ - this.showFromLocationPopup(); - } + } else { this.showErrorMessage(res.message) } @@ -242,6 +237,7 @@ }, openScanPopup() { + if (this.fromLocationCode == "") { this.showFromLocationPopup(); return @@ -250,14 +246,21 @@ }, showFromLocationPopup() { this.$nextTick(() => { - this.$refs.scanFromLocationCode.openScanPopup(); + if(this.showOnePop){ + this.$refs.okToHoldRecordPackRef.showOne = true + }else{ + this.$refs.scanFromLocationCode.openScanPopup(); + } }) }, getFromLocation(location) { this.fromLocationCode = location.code; this.fromLocationInfo = location; if(!this.showOnePop){ - this.openScanPopup(); + this.openScanPopup(); + }else{ + this.itemCode ='' + this.batch ='' } }, getToLocation(location, code) { @@ -265,12 +268,11 @@ this.toLocationInfo = location; }, getScanResult(result,managementType) { - console.log(356,result) if(this.showOnePop){ this.itemCode= result.balance.itemCode this.batch = result.balance.batch - console.log(357,this.itemCode) - console.log(358,this.batch ) + this.isClearItemCode = false + debugger this.getResult = result//存储接受的结果 this.$refs.scanPopup.closeScanPopup() @@ -419,20 +421,20 @@ calcHandleQty(this.detailSource); }, getInputMsgResult(result,fromWitch){ - console.log('pooo',result) if(fromWitch == 'fromLocationScanMsg'){ - this.isClearFromLocationCode = false this.$refs.scanFromLocationCode.getScanResult(result) }else if(fromWitch == 'itemCodeScanMsg'){ - console.log(7878,this.fromLocationCode) result.fromLocationCode = this.fromLocationCode this.$refs.scanPopup.getScanResult(result) } + this.isClearFromLocationCode = false this.$refs.scanFromLocationCode.getScanResult(result) }else if(fromWitch == 'itemCodeScanMsg'){ result.fromLocationCode = this.fromLocationCode this.$refs.scanPopup.getScanResult(result) } }, // 清除来源库位 clearFromLocation(fromLocationCodeParams){ this.fromLocationCode = fromLocationCodeParams - console.log('rwyrwey',this.fromLocationCode) + this.itemCode ='' + this.batch ='' this.isClearFromLocationCode = true }, // 清除零件 - clearItemCode(itemCodeParams){ - this.itemCode = itemCodeParams + clearItemCode(label){ + this.itemCode = label.itemCode + this.batch ='' this.isClearItemCode = true }, showErrorMessage(message) { @@ -595,8 +597,6 @@ var info = getPackingNumberAndBatchByList(this.managementList, detail.itemCode, detail.packingNumber, detail.toLocationCode, detail.batch); var submitItem = deepCopyData(detail) - console.log(233,submitItem) - console.log(244,info) submitItem.itemCode = detail.itemCode; submitItem.itemName = detail.package.itemName; submitItem.itemDesc1 = detail.package.itemDesc1; diff --git a/src/pages/inventoryMove/coms/okToHoldRecordPack.vue b/src/pages/inventoryMove/coms/okToHoldRecordPack.vue index d30b9cfb..2142f178 100644 --- a/src/pages/inventoryMove/coms/okToHoldRecordPack.vue +++ b/src/pages/inventoryMove/coms/okToHoldRecordPack.vue @@ -9,14 +9,14 @@ 来源库位: - + 零件: - + @@ -65,12 +65,11 @@ emits: ["showFromLocationPopup",'itemCodeClick','confirm','getInputMsgResult'], data() { return { - show:true, handleQty:0, fromLocationCode:'', itemCode:'', batch:'', - showOne:true + showOne:false } }, props: { @@ -201,12 +200,13 @@ that.boxfocus = false; }); }, + onClear(){ + console.log(111) + } }, watch: { fromLocationCodeProps:{ handler(newVal, oldVal) { - console.log('wer',this.isClearFromLocationCode) - console.log('wer',newVal) if(this.isClearFromLocationCode){ this.fromLocationCode='' }else{ @@ -220,15 +220,17 @@ handler(newVal, oldVal) { if(this.isClearItemCode){ this.itemCode='' - this.batch='' }else{ this.itemCode = newVal } }, }, batchProps(newVal) { - this.batch = newVal - console.log(999,this.batch) + if(this.isClearItemCode){ + this.batch='' + }else{ + this.batch = newVal + } }, } }