|
@@ -561,8 +561,8 @@ public class PitcherDataServiceImpl implements IPitcherDataService {
|
|
|
@Override
|
|
|
public PitcherGameDataDayTotalVO getPitcherGameDataDayTotal(PitcherGameDataDayTotalDTO dto) {
|
|
|
com.github.sd4324530.jtuple.Tuple2<List<Long>, List<Long>> poerInfo = dataPowerComponent.getPowerInfo(dto.getSourceSystem());
|
|
|
- List<Long> userIds = dto.getPitcherId() == null ? poerInfo.first : Collections.singletonList(dto.getPitcherId());
|
|
|
- List<Long> gameIds = dto.getGameId() == null ? poerInfo.second : Collections.singletonList(Long.parseLong(dto.getGameId()));
|
|
|
+ List<Long> userIds = CollectionUtils.isEmpty(dto.getPitcherId()) ? poerInfo.first : dto.getPitcherId();
|
|
|
+ List<Long> gameIds = CollectionUtils.isEmpty(dto.getGameId()) ? poerInfo.second : dto.getGameId();
|
|
|
//不传递时间,默认查询当天
|
|
|
if (dto.getBeginDate() == null || dto.getEndDate() == null) {
|
|
|
dto.setBeginDate(LocalDate.now());
|
|
@@ -570,10 +570,10 @@ public class PitcherDataServiceImpl implements IPitcherDataService {
|
|
|
}
|
|
|
//创建查询条件
|
|
|
Criteria cri = Cnd.cri();
|
|
|
- if (userIds != null) {
|
|
|
+ if (CollectionUtils.isNotEmpty(userIds)) {
|
|
|
cri.where().andInList("pitcher_id", userIds);
|
|
|
}
|
|
|
- if (gameIds != null) {
|
|
|
+ if (CollectionUtils.isNotEmpty(gameIds)) {
|
|
|
cri.where().andInList("game_id", gameIds);
|
|
|
}
|
|
|
if (StringUtils.isNotBlank(dto.getSourceSystem())) {
|