From 849dc47a156e7523ed9d3dc8ff14962696836bf3 Mon Sep 17 00:00:00 2001 From: liujiang <569804566@qq.com> Date: Thu, 21 Aug 2025 20:48:47 +0800 Subject: [PATCH] =?UTF-8?q?master=EF=BC=9A=E6=A1=A3=E5=8F=A3=E8=B4=AD?= =?UTF-8?q?=E4=B9=B0=E6=8E=A8=E5=B9=BF=E8=90=A5=E9=94=80=E4=BC=98=E5=8C=96?= =?UTF-8?q?=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/ruoyi/xkt/service/impl/AdvertRoundServiceImpl.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/xkt/src/main/java/com/ruoyi/xkt/service/impl/AdvertRoundServiceImpl.java b/xkt/src/main/java/com/ruoyi/xkt/service/impl/AdvertRoundServiceImpl.java index 9320bdedb..6cea53491 100644 --- a/xkt/src/main/java/com/ruoyi/xkt/service/impl/AdvertRoundServiceImpl.java +++ b/xkt/src/main/java/com/ruoyi/xkt/service/impl/AdvertRoundServiceImpl.java @@ -359,8 +359,7 @@ public class AdvertRoundServiceImpl implements IAdvertRoundService { // 当天 final Date voucherDate = java.sql.Date.valueOf(LocalDate.now()); // 获取当前所有 正在投放 和 待投放的推广轮次 - List allRoundList = this.advertRoundMapper.selectList(new LambdaQueryWrapper() - .eq(AdvertRound::getDelFlag, Constants.UNDELETED) + List allRoundList = this.advertRoundMapper.selectList(new LambdaQueryWrapper().eq(AdvertRound::getDelFlag, Constants.UNDELETED) .in(AdvertRound::getLaunchStatus, Arrays.asList(AdLaunchStatus.LAUNCHING.getValue(), AdLaunchStatus.UN_LAUNCH.getValue()))); if (CollectionUtils.isEmpty(allRoundList)) { return new ArrayList<>(); @@ -368,8 +367,7 @@ public class AdvertRoundServiceImpl implements IAdvertRoundService { // 当前 档口 在所有 待投放 及 投放中 的推广轮次竞价失败记录 List allRecordList = this.advertRoundRecordMapper.selectList(new LambdaQueryWrapper() .eq(AdvertRoundRecord::getDelFlag, Constants.UNDELETED).eq(AdvertRoundRecord::getStoreId, storeId) - .eq(AdvertRoundRecord::getVoucherDate, voucherDate) - .in(AdvertRoundRecord::getAdvertRoundId, allRoundList.stream().map(AdvertRound::getId).collect(Collectors.toList()))); + .eq(AdvertRoundRecord::getVoucherDate, voucherDate)); // 按照advertId进行分组,取最小的roundId列表 Map> minRoundIdMap = allRoundList.stream().collect(Collectors.groupingBy(AdvertRound::getAdvertId, Collectors.mapping(AdvertRound::getRoundId, Collectors.minBy(Comparator.comparing(Integer::intValue)))));