From 3512270362c77fe45bc68ab7b6f28bd1bd2f8bfb Mon Sep 17 00:00:00 2001
From: chenrui <1187576398@qq.com>
Date: 星期一, 09 六月 2025 11:58:56 +0800
Subject: [PATCH] 分页修改

---
 src/main/java/com/ruoyi/purchase/service/impl/PaymentRegistrationServiceImpl.java |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/src/main/java/com/ruoyi/purchase/service/impl/PaymentRegistrationServiceImpl.java b/src/main/java/com/ruoyi/purchase/service/impl/PaymentRegistrationServiceImpl.java
index ca69eef..95a51ff 100644
--- a/src/main/java/com/ruoyi/purchase/service/impl/PaymentRegistrationServiceImpl.java
+++ b/src/main/java/com/ruoyi/purchase/service/impl/PaymentRegistrationServiceImpl.java
@@ -288,6 +288,8 @@
             detailPagination.put("pageSize", detailPageSize);
             detailPagination.put("pages", (int) Math.ceil((double) totalDetails / detailPageSize));
 
+            // 搴斾粯閲戦閫昏緫涓嶉噰鐢ㄥ悎鍚岄噾棰濇敼鎴�  鍙戠エ閲戦鍑忎粯娆鹃噾棰�
+            payableAmount = invoiceAmount.subtract(paymentAmount);
             res.put("invoiceAmount", invoiceAmount);
             res.put("payableAmount", payableAmount);
             res.put("paymentAmount", paymentAmount);
@@ -374,7 +376,6 @@
                                                                                 Collectors.toList()
                                                                         )
                                                                         );
-            BigDecimal amountDateTotal = BigDecimal.ZERO;
             for (LocalDate localDate : dateListMap.keySet()) {
                 BigDecimal currentPaymentAmount = BigDecimal.ZERO;
                 BigDecimal invoiceAmount = BigDecimal.ZERO;
@@ -405,6 +406,17 @@
         return result;
     }
 
+    /**
+     * 鏌ヨ浠樻鐧昏鍒楄〃鍒嗛〉
+     *
+     * @param paymentRegistrationDto 浠樻鐧昏
+     * @return 浠樻鐧昏闆嗗悎
+     */
+    @Override
+    public IPage<PaymentRegistrationDto> paymentHistoryListPage(Page page, PaymentRegistrationDto paymentRegistrationDto) {
+        return paymentRegistrationMapper.paymentHistoryListPage(page, paymentRegistrationDto);
+    }
+
     // 鎵归噺鏌ヨ閲囪喘鍙拌处锛堝綋鏈堬級
     private Map<Long, List<PurchaseLedger>> batchQueryPurchaseLedgers(List<Long> supplierIds, LocalDate startDate, LocalDate endDate) {
         LambdaQueryWrapper<PurchaseLedger> query = new LambdaQueryWrapper<>();

--
Gitblit v1.9.3