From a83879c5ace09fcd36093c435593c77ee6cbc694 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AD=A3=E5=9C=A3=E5=8D=8E?= <752718920@qq.com> Date: Tue, 14 Feb 2023 21:09:33 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E5=8D=95=E6=8D=AE=E5=85=B3?= =?UTF-8?q?=E8=81=94=E8=B7=B3=E8=BD=AC=E7=9A=84=E6=97=B6=E5=80=99=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E9=87=91=E9=A2=9D=E8=AE=A1=E7=AE=97=E7=B2=BE=E5=BA=A6?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98=EF=BC=88=E8=A7=A3=E5=86=B3=E5=8D=95?= =?UTF-8?q?=E6=8D=AE=E8=B7=B3=E8=BD=AC=E6=97=B6=E8=AE=A1=E7=AE=97=E7=9A=84?= =?UTF-8?q?bug=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jshERP-web/src/views/bill/modules/PurchaseBackModal.vue | 5 ++++- jshERP-web/src/views/bill/modules/PurchaseInModal.vue | 5 ++++- jshERP-web/src/views/bill/modules/SaleBackModal.vue | 5 ++++- jshERP-web/src/views/bill/modules/SaleOutModal.vue | 5 ++++- 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/jshERP-web/src/views/bill/modules/PurchaseBackModal.vue b/jshERP-web/src/views/bill/modules/PurchaseBackModal.vue index 188b8547..870a44a4 100644 --- a/jshERP-web/src/views/bill/modules/PurchaseBackModal.vue +++ b/jshERP-web/src/views/bill/modules/PurchaseBackModal.vue @@ -405,7 +405,10 @@ this.materialTable.dataSource = listEx ///给优惠后金额重新赋值 allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0 - let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0 + let discount = 0 + if(allTaxLastMoney!==0) { + discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0 + } let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0 this.$nextTick(() => { this.form.setFieldsValue({ diff --git a/jshERP-web/src/views/bill/modules/PurchaseInModal.vue b/jshERP-web/src/views/bill/modules/PurchaseInModal.vue index 6a446d19..80007ff6 100644 --- a/jshERP-web/src/views/bill/modules/PurchaseInModal.vue +++ b/jshERP-web/src/views/bill/modules/PurchaseInModal.vue @@ -449,7 +449,10 @@ this.materialTable.dataSource = listEx ///给优惠后金额重新赋值 allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0 - let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0 + let discount = 0 + if(allTaxLastMoney!==0) { + discount = (discountMoney / allTaxLastMoney * 100).toFixed(2) - 0 + } let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0 let changeAmount = discountLastMoney if(deposit) { diff --git a/jshERP-web/src/views/bill/modules/SaleBackModal.vue b/jshERP-web/src/views/bill/modules/SaleBackModal.vue index 87ac9419..74ec23c0 100644 --- a/jshERP-web/src/views/bill/modules/SaleBackModal.vue +++ b/jshERP-web/src/views/bill/modules/SaleBackModal.vue @@ -416,7 +416,10 @@ this.materialTable.dataSource = listEx ///给优惠后金额重新赋值 allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0 - let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0 + let discount = 0 + if(allTaxLastMoney!==0) { + discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0 + } let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0 this.$nextTick(() => { this.form.setFieldsValue({ diff --git a/jshERP-web/src/views/bill/modules/SaleOutModal.vue b/jshERP-web/src/views/bill/modules/SaleOutModal.vue index 0dd5b840..685dc9d7 100644 --- a/jshERP-web/src/views/bill/modules/SaleOutModal.vue +++ b/jshERP-web/src/views/bill/modules/SaleOutModal.vue @@ -467,7 +467,10 @@ this.materialTable.dataSource = listEx ///给优惠后金额重新赋值 allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0 - let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0 + let discount = 0 + if(allTaxLastMoney!==0) { + discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0 + } let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0 let changeAmount = discountLastMoney if(deposit) {