From c7d9c7f73f92dd8fb2b7cb3f8cfe6841ca956d18 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期三, 12 八月 2026 11:48:57 +0800
Subject: [PATCH] dev_天津_建诚恒商贸 1.供应商往来添加付款功能 2.客户往来添加回款功能

---
 src/views/financialManagement/payable/purchaseIn.vue |   22 +++++++++++++++++++++-
 1 files changed, 21 insertions(+), 1 deletions(-)

diff --git a/src/views/financialManagement/payable/purchaseIn.vue b/src/views/financialManagement/payable/purchaseIn.vue
index 532bcb4..b105859 100644
--- a/src/views/financialManagement/payable/purchaseIn.vue
+++ b/src/views/financialManagement/payable/purchaseIn.vue
@@ -49,6 +49,8 @@
                 :column="columns"
                 :tableData="dataList"
                 :tableLoading="tableLoading"
+                isShowSummary
+                :summaryMethod="getSummaries"
                 :page="{
           current: pagination.currentPage,
           size: pagination.pageSize,
@@ -189,7 +191,25 @@
     getTableData();
   };
 
-  const handleOut = () => {
+  const getSummaries = ({ columns, data }) => {
+  const sums = [];
+  columns.forEach((col, index) => {
+    if (index === 0) {
+      sums[index] = "鍚堣";
+    } else if (col.property === "inboundAmount") {
+      const total = data.reduce((prev, cur) => {
+        const v = Number(cur.inboundAmount);
+        return prev + (isNaN(v) ? 0 : v);
+      }, 0);
+      sums[index] = total.toLocaleString("zh-CN", { minimumFractionDigits: 2, maximumFractionDigits: 2 });
+    } else {
+      sums[index] = "";
+    }
+  });
+  return sums;
+};
+
+const handleOut = () => {
     proxy.download(
       "/accountPurchase/exportAccountPurchaseInbound",
       buildFilterParams(),

--
Gitblit v1.9.3