From 7b65fb8c1001850e468a51c2d9af474621ce7115 Mon Sep 17 00:00:00 2001
From: 44323 <443237572@qq.com>
Date: 星期二, 19 三月 2024 18:11:45 +0800
Subject: [PATCH] Merge branch '2.0' of http://120.76.84.145:10101/gitblit/r/java/PlayPai into 2.0

---
 cloud-server-activity/src/main/java/com/dsh/activity/controller/PointMercharsController.java |   20 +++++++++++++-------
 1 files changed, 13 insertions(+), 7 deletions(-)

diff --git a/cloud-server-activity/src/main/java/com/dsh/activity/controller/PointMercharsController.java b/cloud-server-activity/src/main/java/com/dsh/activity/controller/PointMercharsController.java
index 85c9a57..b3ea633 100644
--- a/cloud-server-activity/src/main/java/com/dsh/activity/controller/PointMercharsController.java
+++ b/cloud-server-activity/src/main/java/com/dsh/activity/controller/PointMercharsController.java
@@ -226,10 +226,12 @@
                 String endTime = (String) stringObjectMap.get("endTime");
                 stringObjectMap.put("timeValue", startTime + "至" + endTime);
                 int count1 = upmseService.count(new LambdaQueryWrapper<UserPointsMerchandise>()
-                        .eq(UserPointsMerchandise::getPointsMerchandiseId, o));
+                        .eq(UserPointsMerchandise::getPointsMerchandiseId, o)
+                        .eq(UserPointsMerchandise::getPayStatus, 2).eq(UserPointsMerchandise::getState, 1));
                 int count2 = upmseService.count(new LambdaQueryWrapper<UserPointsMerchandise>()
                         .eq(UserPointsMerchandise::getPointsMerchandiseId, o)
-                        .eq(UserPointsMerchandise::getStatus, 2));
+                        .eq(UserPointsMerchandise::getStatus, 2)
+                        .eq(UserPointsMerchandise::getPayStatus, 2).eq(UserPointsMerchandise::getState, 1));
                 stringObjectMap.put("hasExchangeQty", count1);
                 stringObjectMap.put("hasPickQty", count2);
 
@@ -1361,7 +1363,6 @@
     @PostMapping("/base/pointMerchars/updateDetailsUserPointMercase")
     public void updateDetailsUserPointMercase(@RequestBody UserPointsMerchandise merchandise) {
         merchandise.setUserId(null);
-        merchandise.setPointsMerchandiseId(null);
         upmseService.updateById(merchandise);
     }
 
@@ -1440,8 +1441,6 @@
     @PostMapping("/base/pointMerchars/getConsumeDetails")
     public List<ConsumeDetail> getConsumeDetails(@RequestBody BillingDataRequestVo requestVo) {
         return upmseService.getConsumeDetails(requestVo);
-
-
     }
 
 
@@ -1710,12 +1709,19 @@
                 }
             }else if (byId.getUseScope()==4){
                 // 如果是指定场地
-                List<Integer> collect1 = list.stream().map(PointsMerchandiseStore::getSiteId).collect(Collectors.toList());
+                List<Integer> collect1 = list.stream().map(PointsMerchandiseStore::getSiteId).distinct().collect(Collectors.toList());
                 int temp =0;
                 List<Integer> collect = list.stream().map(PointsMerchandiseStore::getStoreId).collect(Collectors.toList());
+                List<Store> stores1 = new ArrayList<>();
+                for (Integer integer : collect) {
+                    List<Integer> list1 = new ArrayList<>();
+                    list1.add(integer);
+                    List<Store> stores = stoClient.queryStoreByIds(list1);
+                    stores1.addAll(stores);
+                }
                 List<Store> stores = stoClient.queryStoreByIds(collect);
                 while (temp!=collect1.size()){
-                    for (Store store : stores) {
+                    for (Store store : stores1) {
                         Integer integer = collect1.get(temp);
                         Site site = siteClient.querySiteById(integer);
                         StoreVos storeVos1 = new StoreVos();

--
Gitblit v1.7.1