From 8b749305a8e8c3f4bf669f6980edf2bbb7bfa9c7 Mon Sep 17 00:00:00 2001
From: chenhj <1263187585@qq.com>
Date: 星期五, 24 四月 2026 11:14:34 +0800
Subject: [PATCH] Merge branch 'dev_New_pro' of http://114.132.189.42:9002/r/product-inventory-management-after into dev_New_pro

---
 src/main/java/com/ruoyi/waterrecord/controller/WaterRecordController.java |   20 ++++++++++++--------
 1 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/src/main/java/com/ruoyi/waterrecord/controller/WaterRecordController.java b/src/main/java/com/ruoyi/waterrecord/controller/WaterRecordController.java
index 87a9b7d..be3933b 100644
--- a/src/main/java/com/ruoyi/waterrecord/controller/WaterRecordController.java
+++ b/src/main/java/com/ruoyi/waterrecord/controller/WaterRecordController.java
@@ -9,15 +9,16 @@
 import com.ruoyi.framework.web.domain.AjaxResult;
 import com.ruoyi.waterrecord.pojo.WaterRecord;
 import com.ruoyi.waterrecord.service.WaterRecordService;
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import io.swagger.v3.oas.annotations.Operation;
+import lombok.AllArgsConstructor;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.CollectionUtils;
 import org.springframework.web.bind.annotation.*;
 import org.springframework.web.multipart.MultipartFile;
 
-import javax.servlet.http.HttpServletResponse;
+import jakarta.servlet.http.HttpServletResponse;
 import java.util.List;
 
 /**
@@ -25,11 +26,11 @@
  * @date : 2025/8/11 10:08
  */
 @RestController
-@Api(tags = "鐢ㄦ按绠$悊")
+@Tag(name = "鐢ㄦ按绠$悊")
 @RequestMapping("/waterRecord")
+@AllArgsConstructor
 public class WaterRecordController extends BaseController {
 
-    @Autowired
     private WaterRecordService waterRecordService;
 
     @GetMapping("/listPage")
@@ -69,7 +70,7 @@
      */
     @Log(title = "瀵煎叆鐢ㄦ按绠$悊", businessType = BusinessType.IMPORT)
     @PostMapping("/importData")
-    @ApiOperation("瀵煎叆鐢ㄦ按绠$悊")
+    @Operation(summary = "瀵煎叆鐢ㄦ按绠$悊")
     public AjaxResult importData(MultipartFile file) throws Exception {
         return waterRecordService.importData(file);
     }
@@ -79,10 +80,13 @@
      */
     @Log(title = "瀵煎嚭鐢ㄦ按绠$悊", businessType = BusinessType.EXPORT)
     @PostMapping("/export")
-    @ApiOperation("瀵煎嚭鐢ㄦ按绠$悊")
+    @Operation(summary = "瀵煎嚭鐢ㄦ按绠$悊")
     public void export(HttpServletResponse response) {
+        Page page = new Page(-1,-1);
+        WaterRecord waterRecord = new WaterRecord();
+        IPage<WaterRecord> listPage = waterRecordService.listPage(page, waterRecord);
         ExcelUtil<WaterRecord> util = new ExcelUtil<WaterRecord>(WaterRecord.class);
-        util.exportExcel(response, null , "鐢ㄦ按绠$悊");
+        util.exportExcel(response, listPage.getRecords() , "鐢ㄦ按绠$悊");
     }
 
 }

--
Gitblit v1.9.3