Browse Source

修改内容:排行榜bug修改

lth 1 year ago
parent
commit
09e241bae9

+ 2 - 1
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/dto/AdsAgentRechargeRankingListDTO.java

@@ -4,6 +4,7 @@ import com.zanxiang.game.data.serve.pojo.base.BasePage;
 import lombok.Data;
 import lombok.Data;
 
 
 import java.time.LocalDate;
 import java.time.LocalDate;
+import java.util.List;
 
 
 @Data
 @Data
 public class AdsAgentRechargeRankingListDTO extends BasePage {
 public class AdsAgentRechargeRankingListDTO extends BasePage {
@@ -14,7 +15,7 @@ public class AdsAgentRechargeRankingListDTO extends BasePage {
 
 
     private String sourceSystem;
     private String sourceSystem;
 
 
-    private String agentId;
+    private List<String> agentId;
 
 
     private Long pitcherId;
     private Long pitcherId;
 
 

+ 1 - 2
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/AdsAccountRechargeRankingServiceImpl.java

@@ -1,7 +1,6 @@
 package com.zanxiang.game.data.serve.service.impl;
 package com.zanxiang.game.data.serve.service.impl;
 
 
 import com.google.common.base.CaseFormat;
 import com.google.common.base.CaseFormat;
-import com.zanxiang.erp.security.util.SecurityUtil;
 import com.zanxiang.game.data.serve.component.DataPowerComponent;
 import com.zanxiang.game.data.serve.component.DataPowerComponent;
 import com.zanxiang.game.data.serve.pojo.dto.AdsAccountRechargeRankingListDTO;
 import com.zanxiang.game.data.serve.pojo.dto.AdsAccountRechargeRankingListDTO;
 import com.zanxiang.game.data.serve.pojo.vo.AdsAccountRechargeRankingVO;
 import com.zanxiang.game.data.serve.pojo.vo.AdsAccountRechargeRankingVO;
@@ -39,7 +38,7 @@ public class AdsAccountRechargeRankingServiceImpl implements IAdsAccountRecharge
     @Override
     @Override
     public Page<AdsAccountRechargeRankingVO> listOfPage(AdsAccountRechargeRankingListDTO dto) {
     public Page<AdsAccountRechargeRankingVO> listOfPage(AdsAccountRechargeRankingListDTO dto) {
         List<Long> userIds = dto.getPitcherId() == null ? dataPowerComponent.getSubUserIdList() : Collections.singletonList(dto.getPitcherId());
         List<Long> userIds = dto.getPitcherId() == null ? dataPowerComponent.getSubUserIdList() : Collections.singletonList(dto.getPitcherId());
-        List<Long> gameIds = dto.getPitcherId() == null ? dataPowerComponent.getSubGameIdList() : Collections.singletonList(dto.getGameId());
+        List<Long> gameIds = dto.getGameId() == null ? dataPowerComponent.getSubGameIdList() : Collections.singletonList(dto.getGameId());
         if (StringUtils.isBlank(dto.getSortFiled())) {
         if (StringUtils.isBlank(dto.getSortFiled())) {
             dto.setSortFiled("cost");
             dto.setSortFiled("cost");
         }
         }

+ 2 - 4
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/AdsAgentRechargeRankingServiceImpl.java

@@ -1,10 +1,8 @@
 package com.zanxiang.game.data.serve.service.impl;
 package com.zanxiang.game.data.serve.service.impl;
 
 
 import com.google.common.base.CaseFormat;
 import com.google.common.base.CaseFormat;
-import com.zanxiang.erp.security.util.SecurityUtil;
 import com.zanxiang.game.data.serve.component.DataPowerComponent;
 import com.zanxiang.game.data.serve.component.DataPowerComponent;
 import com.zanxiang.game.data.serve.pojo.dto.AdsAgentRechargeRankingListDTO;
 import com.zanxiang.game.data.serve.pojo.dto.AdsAgentRechargeRankingListDTO;
-import com.zanxiang.game.data.serve.pojo.entity.AdsAgentRechargeRanking;
 import com.zanxiang.game.data.serve.pojo.vo.AdsAgentRechargeRankingVO;
 import com.zanxiang.game.data.serve.pojo.vo.AdsAgentRechargeRankingVO;
 import com.zanxiang.game.data.serve.service.IAdsAgentRechargeRankingService;
 import com.zanxiang.game.data.serve.service.IAdsAgentRechargeRankingService;
 import com.zanxiang.game.data.serve.utils.Page;
 import com.zanxiang.game.data.serve.utils.Page;
@@ -61,8 +59,8 @@ public class AdsAgentRechargeRankingServiceImpl implements IAdsAgentRechargeRank
         if (null != dto.getBeginDay() && null != dto.getEndDay()) {
         if (null != dto.getBeginDay() && null != dto.getEndDay()) {
             cri.where().and("dt", ">=", dto.getBeginDay()).and("dt", "<=", dto.getEndDay());
             cri.where().and("dt", ">=", dto.getBeginDay()).and("dt", "<=", dto.getEndDay());
         }
         }
-        if (StringUtils.isNotBlank(dto.getAgentId())) {
-            cri.where().and("agent_id", "=", dto.getAgentId());
+        if (CollectionUtils.isNotEmpty(dto.getAgentId())) {
+            cri.where().andIn("agent_id", dto.getAgentId().toArray(String[]::new));
         }
         }
         if (userIds != null) {
         if (userIds != null) {
             cri.where().andInList("pitcher_id", userIds);
             cri.where().andInList("pitcher_id", userIds);

+ 1 - 1
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/AdsOrderDetailService.java

@@ -43,7 +43,7 @@ public class AdsOrderDetailService implements IAdsOrderDetailService {
     @Override
     @Override
     public Page<AdsOrderDetailVO> listOfPage(AdsOrderDetailListDTO dto) {
     public Page<AdsOrderDetailVO> listOfPage(AdsOrderDetailListDTO dto) {
         List<Long> userIds = dto.getPitcherId() == null ? dataPowerComponent.getSubUserIdList() : Collections.singletonList(Long.parseLong(dto.getPitcherId()));
         List<Long> userIds = dto.getPitcherId() == null ? dataPowerComponent.getSubUserIdList() : Collections.singletonList(Long.parseLong(dto.getPitcherId()));
-        List<Long> gameIds = dto.getGameId() == null ? dataPowerComponent.getSubGameIdList() : dto.getGameId();
+        List<Long> gameIds = CollectionUtils.isEmpty(dto.getGameId()) ? dataPowerComponent.getSubGameIdList() : dto.getGameId();
         if (StringUtils.isBlank(dto.getPitcherId()) && !SecurityUtil.isManager()) {
         if (StringUtils.isBlank(dto.getPitcherId()) && !SecurityUtil.isManager()) {
             // 只有管理员才能查看全部数据
             // 只有管理员才能查看全部数据
             dto.setPitcherId(SecurityUtil.getUserId().toString());
             dto.setPitcherId(SecurityUtil.getUserId().toString());