From 0d6589b59c64f7662e749950f69da75ae59c1b08 Mon Sep 17 00:00:00 2001 From: Vayne Date: Sun, 2 Apr 2023 14:35:40 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=88=E8=AE=A1=E5=88=97=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../scm/basicInformation/purchaseorder/purchasebackForm.vue | 6 +++--- SC-web/src/views/scm/basicInformation/tradeupload/Form2.vue | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/SC-web/src/views/scm/basicInformation/purchaseorder/purchasebackForm.vue b/SC-web/src/views/scm/basicInformation/purchaseorder/purchasebackForm.vue index c53335d7..f05fbdec 100644 --- a/SC-web/src/views/scm/basicInformation/purchaseorder/purchasebackForm.vue +++ b/SC-web/src/views/scm/basicInformation/purchaseorder/purchasebackForm.vue @@ -369,7 +369,7 @@ sums[index] = values.reduce((prev, curr) => { const value = Number(curr); if (!isNaN(value)) { - return this.jnpf.floatAdd(prev,curr); + return Math.round(this.jnpf.floatAdd(prev,curr)*1000000)/1000000; } else { return prev; } @@ -432,8 +432,8 @@ var refundNum = 0; purchaseorder.purchaseorder_item0List.forEach((item, index)=>{ item.purchaseorderItem0Id = item.id; - refundAmount = refundAmount + parseFloat(item.amount); - refundNum = refundNum + parseFloat(item.settlement); + refundAmount = this.jnpf.floatAdd(refundAmount,item.amount); + refundNum = this.jnpf.floatAdd(refundNum,item.settlement); }); this.dataForm.refundAmount = refundAmount; this.dataForm.refundNum = refundNum; diff --git a/SC-web/src/views/scm/basicInformation/tradeupload/Form2.vue b/SC-web/src/views/scm/basicInformation/tradeupload/Form2.vue index f02017c9..4751b15c 100644 --- a/SC-web/src/views/scm/basicInformation/tradeupload/Form2.vue +++ b/SC-web/src/views/scm/basicInformation/tradeupload/Form2.vue @@ -231,6 +231,7 @@ materialId: "", customerId: "", supplierId: "", + supplierName: "", salesId: "", vehicleId: "", vehiclePictures: [], @@ -475,6 +476,7 @@ }, customerSelect2(a, b) { this.dataForm.supplierId = b.code; + this.dataForm.supplierName = b.name; }, handleAvatarSuccess(res, file) { this.imageUrl = URL.createObjectURL(file.raw);