From 1555d7397fa044d95533b62d6ef75f5bcdc3da8f Mon Sep 17 00:00:00 2001
From: yuan <123@>
Date: 星期六, 23 五月 2026 22:24:41 +0800
Subject: [PATCH] 修改单价保留6位小数

---
 src/views/procurementManagement/procurementLedger/index.vue |   13 ++++++++-----
 1 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/src/views/procurementManagement/procurementLedger/index.vue b/src/views/procurementManagement/procurementLedger/index.vue
index 9bbe87e..1b6b268 100644
--- a/src/views/procurementManagement/procurementLedger/index.vue
+++ b/src/views/procurementManagement/procurementLedger/index.vue
@@ -68,7 +68,7 @@
               <el-table-column label="鍙敤鏁伴噺" prop="availableQuality" />
               <el-table-column label="閫�璐ф暟閲�" prop="returnQuality" />
               <el-table-column label="绋庣巼(%)" prop="taxRate" />
-              <el-table-column label="鍚◣鍗曚环(鍏�)" prop="taxInclusiveUnitPrice" :formatter="formattedNumber" />
+              <el-table-column label="鍚◣鍗曚环(鍏�)" prop="taxInclusiveUnitPrice" :formatter="unitPriceFormatter" />
               <el-table-column label="鍚◣鎬讳环(鍏�)" prop="taxInclusiveTotalPrice" :formatter="formattedNumber" />
               <el-table-column label="涓嶅惈绋庢�讳环(鍏�)" prop="taxExclusiveTotalPrice" :formatter="formattedNumber" />
             </el-table>
@@ -210,7 +210,7 @@
           <el-table-column label="鏁伴噺" prop="quantity" width="70" />
           <el-table-column label="搴撳瓨棰勮鏁伴噺" prop="warnNum" width="120" show-overflow-tooltip />
           <el-table-column label="绋庣巼(%)" prop="taxRate" width="80" />
-          <el-table-column label="鍚◣鍗曚环(鍏�)" prop="taxInclusiveUnitPrice" :formatter="formattedNumber" width="150" />
+          <el-table-column label="鍚◣鍗曚环(鍏�)" prop="taxInclusiveUnitPrice" :formatter="unitPriceFormatter" width="150" />
           <el-table-column label="鍚◣鎬讳环(鍏�)" prop="taxInclusiveTotalPrice" :formatter="formattedNumber" width="150" />
           <el-table-column label="涓嶅惈绋庢�讳环(鍏�)" prop="taxExclusiveTotalPrice" :formatter="formattedNumber" width="150" />
           <el-table-column label="鏄惁璐ㄦ" prop="isChecked" width="150">
@@ -310,7 +310,7 @@
         <el-row :gutter="30">
           <el-col :span="12">
             <el-form-item label="鍚◣鍗曚环(鍏�)锛�" prop="taxInclusiveUnitPrice">
-              <el-input-number v-model="productForm.taxInclusiveUnitPrice" :precision="2" :step="0.1" :min="0" clearable
+              <el-input-number v-model="productForm.taxInclusiveUnitPrice" :precision="6" :step="0.1" :min="0" clearable
                 style="width: 100%" @change="mathNum" />
             </el-form-item>
           </el-col>
@@ -772,6 +772,9 @@
 
 const formattedNumber = (row, column, cellValue) => {
   return parseFloat(cellValue).toFixed(2);
+};
+const unitPriceFormatter = (row, column, cellValue) => {
+  return parseFloat(cellValue).toFixed(6);
 };
 // 鏌ヨ鍒楄〃
 /** 鎼滅储鎸夐挳鎿嶄綔 */
@@ -1476,7 +1479,7 @@
       productForm.value.taxInclusiveUnitPrice = (
         Number(productForm.value.taxInclusiveTotalPrice) /
         Number(productForm.value.quantity)
-      ).toFixed(2);
+      ).toFixed(6);
       // 纭繚缁撴灉涓嶄负璐熸暟
       if (Number(productForm.value.taxInclusiveUnitPrice) < 0) {
         productForm.value.taxInclusiveUnitPrice = "0";
@@ -1517,7 +1520,7 @@
       productForm.value.taxInclusiveUnitPrice = (
         Number(productForm.value.taxInclusiveTotalPrice) /
         Number(productForm.value.quantity)
-      ).toFixed(2);
+      ).toFixed(6);
       // 纭繚缁撴灉涓嶄负璐熸暟
       if (Number(productForm.value.taxInclusiveUnitPrice) < 0) {
         productForm.value.taxInclusiveUnitPrice = "0";

--
Gitblit v1.9.3