From 60de92280e4cd66a914f41b0681656a62cde346d Mon Sep 17 00:00:00 2001
From: Pu Zhibing <393733352@qq.com>
Date: 星期二, 14 一月 2025 14:50:52 +0800
Subject: [PATCH] 修改bug
---
ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopBalanceStatementController.java | 13 ++++++++++++-
1 files changed, 12 insertions(+), 1 deletions(-)
diff --git a/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopBalanceStatementController.java b/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopBalanceStatementController.java
index 083414e..82218b8 100644
--- a/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopBalanceStatementController.java
+++ b/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopBalanceStatementController.java
@@ -25,6 +25,8 @@
import javax.annotation.Resource;
import javax.servlet.http.HttpServletResponse;
import java.math.BigDecimal;
+import java.time.LocalDateTime;
+import java.time.LocalTime;
import java.util.Collection;
import java.util.List;
import java.util.List;
@@ -165,11 +167,20 @@
* @return
*/
@PostMapping("/getShopBalanceStatementList")
- public R<List<ShopBalanceStatement>> getShopBalanceStatementList(@RequestParam("types") Collection<Integer> types, @RequestParam("objectId") Long objectId){
+ public R<List<ShopBalanceStatement>> getShopBalanceStatementList(@RequestParam("types") Collection<Integer> types, @RequestParam(value = "objectId",required = false) Long objectId){
List<ShopBalanceStatement> list = shopBalanceStatementService.list(new LambdaQueryWrapper<ShopBalanceStatement>()
.eq(objectId != null,ShopBalanceStatement::getObjectId, objectId)
.in(types !=null && !types.isEmpty(),ShopBalanceStatement::getType, types));
return R.ok(list);
}
+
+ @PostMapping("/getShopBalanceStatementList2")
+ public R<List<ShopBalanceStatement>> getShopBalanceStatementList2(@RequestParam("type") Integer type,
+ @RequestParam(value = "date") LocalDateTime date){
+ List<ShopBalanceStatement> list = shopBalanceStatementService.list(new LambdaQueryWrapper<ShopBalanceStatement>()
+ .eq(ShopBalanceStatement::getType, type)
+ .between(ShopBalanceStatement::getCreateTime, date.with(LocalTime.MIN), date.with(LocalTime.MAX)));
+ return R.ok(list);
+ }
}
--
Gitblit v1.7.1