From 24f67a128222fc56923a430ba496ea9d2207d068 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=BF=97=E5=9B=BD?= <854933521@qq.com> Date: Fri, 25 Oct 2024 15:08:48 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=8C=89=E8=AE=A1=E5=88=92?= =?UTF-8?q?=E5=AE=8C=E5=B7=A5=202024/8/3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/fg/coms/comNoReceiptPopup.vue | 15 ++++++++------- src/pages/fg/receiptByPlan.vue | 4 +++- src/pages/fg/receiptNoPlan.vue | 24 +++++++++++++++++------- 3 files changed, 28 insertions(+), 15 deletions(-) diff --git a/src/pages/fg/coms/comNoReceiptPopup.vue b/src/pages/fg/coms/comNoReceiptPopup.vue index 91b9983f..aa6ce59a 100644 --- a/src/pages/fg/coms/comNoReceiptPopup.vue +++ b/src/pages/fg/coms/comNoReceiptPopup.vue @@ -27,21 +27,22 @@ - + 物料代码: @@ -158,7 +159,6 @@ export default { showProductLineSelect: false, productLineList: [], productionLineName: "请选择生产线", - productLineCode: "", batch: "", packUnitName: "请选择包装规格", packUnit: "", @@ -176,7 +176,6 @@ export default { rawLocationCode: "", workshop: "", bomVersion: "", - uom: "" } }, props: { @@ -194,7 +193,7 @@ export default { openRequestPopup() { this.initData(); this.planDate = getCurrDate() - this.batch = this.planDate.replace('-', '') + this.batch = this.planDate.replace('-', '').replace('-', '') this.$refs.popup.open('bottom') }, initData() { @@ -322,11 +321,12 @@ export default { this.planQty = 0; this.goodQty = 0 this.planNumber = "" + this.bomVersion = "" }, confirmSelectDate(data) { this.planDate = data[0].label - this.batch = this.planDate.replace('-', ''); + this.batch = this.planDate.replace('-', '').replace('-', ''); }, showSelectDate() { @@ -463,6 +463,7 @@ export default { let pack = this.packUnitList.filter(r => r.packUnit == this.packUnit); this.packQtyHint = pack[0].packQty + "(" + this .getUomInfo(pack[0].uom) + ")"; + this.uom = this.getUomInfo(pack[0].uom); this.packQty = pack[0].packQty }, getUomInfo(uom) { diff --git a/src/pages/fg/receiptByPlan.vue b/src/pages/fg/receiptByPlan.vue index 507b1169..eda06576 100644 --- a/src/pages/fg/receiptByPlan.vue +++ b/src/pages/fg/receiptByPlan.vue @@ -295,6 +295,8 @@ const commit = async () => { } uni.hideLoading() showCommitSuccessMessage('提交成功
生成装配收货记录
', list) + showList.value = []; + dataContent.value.handleQty = 0; } catch (error) { uni.hideLoading() const hint = error.message ? error.message : error @@ -368,7 +370,7 @@ const getScanResult = (result) => { }) } const calcFgQty = () => { - dataContent.value.handleQty = allList.value.length + dataContent.value.handleQty = showList.value.length if (dataContent.value.handleQty == dataContent.value.packQty) { if (scanPopup.value) { scanPopup.value.closeScanPopup() diff --git a/src/pages/fg/receiptNoPlan.vue b/src/pages/fg/receiptNoPlan.vue index 0e1526e5..d9f4561b 100644 --- a/src/pages/fg/receiptNoPlan.vue +++ b/src/pages/fg/receiptNoPlan.vue @@ -16,9 +16,15 @@
- 计划数 + 报工数量 {{dataContent.planQty}}{{dataContent.uom}} + + + 已报工数量 + {{scanedQty}}{{dataContent.uom}} + + @@ -140,7 +146,8 @@ export default { allList: [], index: 1, loadingType: "", - pageSize: 20 + pageSize: 20, + scanedQty: 0 }; }, @@ -260,6 +267,7 @@ export default { title: "提交中...", mask: true }) + let params = this.setParams() console.log(JSON.stringify(params)) @@ -296,10 +304,12 @@ export default { createInspectRequestByPlan(list[0].requestNumber) }) } - - uni.hideLoading() this.showCommitSuccessMessage("提交成功
生成装配收货记录
" + list[0].requestNumber, list) - + this.scanedQty = this.scanedQty + this.showList.length; + this.showList = []; + this.dataContent.handleQty = 0; + this.$forceUpdate(); + uni.hideLoading() } catch (error) { uni.hideLoading() var hint = error.message ? error.message : error @@ -381,7 +391,7 @@ export default { }, calcFgQty() { - this.dataContent.handleQty = this.allList.length; + this.dataContent.handleQty = this.showList.length; if (this.dataContent.handleQty == this.dataContent.packQty) { if (this.$refs.scanPopup) { this.$refs.scanPopup.closeScanPopup(); @@ -404,7 +414,7 @@ export default { showCommitSuccessMessage(hint, pointData) { this.$refs.comMessage.showSuccessMessage(hint, res => { if (pointData.length > 0) { - uni.redirectTo({ + uni.navigateTo({ url: `/pages/point/index?points=${JSON.stringify(pointData)}` }); }