From a6cd21d0d3175702e97d6d707b0fcb3bde9357fd Mon Sep 17 00:00:00 2001 From: xiangxy Date: Thu, 21 Jul 2022 15:11:16 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=9D=A1=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/xinrui/equipment/ScanInStore.vue | 8 +++++++- src/pages/xinrui/equipment/ScanOutStore.vue | 8 +++++++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/pages/xinrui/equipment/ScanInStore.vue b/src/pages/xinrui/equipment/ScanInStore.vue index e338e80..240f227 100644 --- a/src/pages/xinrui/equipment/ScanInStore.vue +++ b/src/pages/xinrui/equipment/ScanInStore.vue @@ -75,7 +75,7 @@ export default { val2: this.$store.getters.materObj.bill_code || '', val3: this.$store.getters.materObj.material_name || '', val4: this.$store.getters.materObj.need_qty || '', - val5: this.$store.getters.materObj.finish_qty || '', + val5: '0', dataList: [], pkId: '', pkObj: {}, @@ -103,6 +103,7 @@ export default { this.dataList.push(res.content) } } + this.val5 = this.dataList.length } else { this.Dialog(res.desc) } @@ -141,6 +142,11 @@ export default { this.disabled1 = false return } + if (this.dataList.length > this.val4) { + this.toast('扫码数不能大于待入数') + this.disabled1 = false + return + } this._confirmDis() } } diff --git a/src/pages/xinrui/equipment/ScanOutStore.vue b/src/pages/xinrui/equipment/ScanOutStore.vue index 5207dab..68239f4 100644 --- a/src/pages/xinrui/equipment/ScanOutStore.vue +++ b/src/pages/xinrui/equipment/ScanOutStore.vue @@ -77,7 +77,7 @@ export default { val2: this.$store.getters.materObj.bill_code || '', val3: this.$store.getters.materObj.material_name || '', val4: this.$store.getters.materObj.need_qty || '', - val5: this.$store.getters.materObj.finish_qty || '', + val5: '0', dataList: [], pkId: '', pkObj: {}, @@ -105,6 +105,7 @@ export default { this.dataList.push(res.content) } } + this.val5 = this.dataList.length } else { this.Dialog(res.desc) } @@ -143,6 +144,11 @@ export default { this.disabled1 = false return } + if (this.dataList.length > this.val4) { + this.toast('扫码数不能大于待出数') + this.disabled1 = false + return + } this._confirmDis() } }