From 21b01ae12c8b7d75e8af59a4d165f08debf691d7 Mon Sep 17 00:00:00 2001 From: yewj Date: Fri, 23 Aug 2024 18:43:06 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A1=AE=E8=AE=A4=E5=8D=95=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 2 +- src/views/collect/DealOrder.vue | 91 +++++++++++++++++++-------------- 2 files changed, 53 insertions(+), 40 deletions(-) diff --git a/.env.development b/.env.development index 2449bf59..5bd315d5 100644 --- a/.env.development +++ b/.env.development @@ -6,7 +6,7 @@ ENV = 'development' # 开发环境 # VUE_APP_BASE_API = 'https://mudi.dsxyy.org/UDI_WMS_MC/' -VUE_APP_BASE_API = 'http://127.0.0.1:9991' +VUE_APP_BASE_API = 'http://192.168.0.166:9991' VUE_APP_SYNC_API ="http://127.0.0.1:10001" # 应用访问路径 例如使用前缀 /admin/ diff --git a/src/views/collect/DealOrder.vue b/src/views/collect/DealOrder.vue index 20493126..156f64da 100644 --- a/src/views/collect/DealOrder.vue +++ b/src/views/collect/DealOrder.vue @@ -25,12 +25,12 @@ - - - - - - + + + + + + @@ -56,7 +56,7 @@ 处理完成 @@ -209,14 +209,14 @@ :prescribeData="curRow" > - - - - - - - - + + + + + + + + { if (res.code == 20000) { - if (res.data.list.length > 0){ + if (res.data.list.length > 0) { this.formData = res.data.list[0] } } @@ -454,9 +455,9 @@ export default { if (this.formDataVisible.scanType == 1) { this.findFromInvList(""); } - if (this.formData.billNo != null){ + if (this.formData.billNo != null) { this.getBillNo(this.formData.billNo) - }else { + } else { this.findCurOrder(); } @@ -689,25 +690,39 @@ export default { }); }, - finishOrder() { + confirmFinishOrder() { this.$confirm('是否确定完成此单据?', '提示', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' }).then(() => { - finishOrder(this.formData).then(res => { - this.loading = false - if (res.code == 20000) { - this.formData = {tagStatus: -1}; - this.curRow = null - this.refreshCodesPanel(this) - } - }).catch(() => { - this.loading = false - }) + this.finishOrder() }).catch(() => { }); + }, + finishOrder() { + finishOrder(this.formData).then(res => { + this.loading = false + if (res.code == 20000) { + this.formData = {tagStatus: -1}; + this.curRow = null + this.formData.confirmFinish = false; + this.refreshCodesPanel(this) + } else if (res.code == 502) { + this.$confirm(res.message, '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(() => { + this.formData.confirmFinish = true; + this.finishOrder(); + }).catch(() => { + }); + } + }).catch(() => { + this.loading = false + }) }, updateOrder() { @@ -878,8 +893,6 @@ export default { } - - } }