From 3ab45f295fb26c7794b4829976f3fb20c68a012e Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期四, 22 一月 2026 10:33:41 +0800
Subject: [PATCH] 新疆海川开心 1.采购模块的计算都改为保留三位小数并且不四舍五入

---
 src/views/procurementManagement/invoiceEntry/index.vue |   19 ++++++++++---------
 1 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/src/views/procurementManagement/invoiceEntry/index.vue b/src/views/procurementManagement/invoiceEntry/index.vue
index ea77ad4..464f897 100644
--- a/src/views/procurementManagement/invoiceEntry/index.vue
+++ b/src/views/procurementManagement/invoiceEntry/index.vue
@@ -40,7 +40,7 @@
         <div>
           <el-button @click="handleExport" style="margin-right: 10px">瀵煎嚭</el-button>
           <el-button type="primary" @click="handleAdd('add')">
-            鏂板鐧昏
+            鏉ョエ鐧昏
           </el-button>
 <!--          <el-button type="danger" plain @click="handleDelete">鍒犻櫎</el-button>-->
         </div>
@@ -89,6 +89,7 @@
 import ExpandTable from "./components/ExpandTable.vue";
 import Modal from "./components/Modal.vue";
 import {ElMessageBox} from "element-plus";
+import { truncate } from "@/utils/index.js";
 
 defineOptions({
   name: "鏉ョエ鐧昏",
@@ -149,7 +150,7 @@
       prop: "contractAmount",
       width:200,
       formatData: (val) => {
-        return val ? parseFloat(val).toFixed(2) : 0;
+        return val ? truncate(parseFloat(val), 3) : 0;
       },
     },
     {
@@ -157,7 +158,7 @@
       prop: "receiptPaymentAmount",
       width:200,
       formatData: (val) => {
-        return val ? parseFloat(val).toFixed(2) : 0;
+        return val ? truncate(parseFloat(val), 3) : 0;
       },
     },
     {
@@ -165,7 +166,7 @@
       prop: "unReceiptPaymentAmount",
       width:200,
       formatData: (val) => {
-        return val ? parseFloat(val).toFixed(2) : 0;
+        return val ? truncate(parseFloat(val), 3) : 0;
       },
     },
     // {
@@ -186,11 +187,11 @@
 };
 
 const handleAdd = (type) => {
-  if (selectedRows.value.length !== 1) {
-    proxy.$modal.msgWarning("璇峰厛閫変腑涓�鏉℃暟鎹�");
-    return;
-  }
-  modalRef.value.open(type, selectedRows.value[0].id);
+	if (selectedRows.value.length < 1) {
+		proxy.$modal.msgWarning("璇疯嚦灏戦�変腑涓�鏉℃暟鎹�");
+		return;
+	}
+	modalRef.value.open(type, selectedRows.value);
 };
 
 const handleEdit = (type, id) => {

--
Gitblit v1.9.3