Commit c8f1269d6ede6fe21d68b9f456921702061a522f
1 parent
1d9db487
promotion:修复砍价活动返回的 combinationPrice 为空的问题
Showing
13 changed files
with
63 additions
and
42 deletions
yudao-framework/yudao-spring-boot-starter-mybatis/src/main/java/cn/iocoder/yudao/framework/mybatis/core/mapper/BaseMapperX.java
| @@ -56,7 +56,7 @@ public interface BaseMapperX<T> extends MPJBaseMapper<T> { | @@ -56,7 +56,7 @@ public interface BaseMapperX<T> extends MPJBaseMapper<T> { | ||
| 56 | } | 56 | } |
| 57 | 57 | ||
| 58 | default Long selectCount() { | 58 | default Long selectCount() { |
| 59 | - return selectCount(new QueryWrapper<T>()); | 59 | + return selectCount(new QueryWrapper<>()); |
| 60 | } | 60 | } |
| 61 | 61 | ||
| 62 | default Long selectCount(String field, Object value) { | 62 | default Long selectCount(String field, Object value) { |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/combination/CombinationActivityController.java
| @@ -74,7 +74,7 @@ public class CombinationActivityController { | @@ -74,7 +74,7 @@ public class CombinationActivityController { | ||
| 74 | @PreAuthorize("@ss.hasPermission('promotion:combination-activity:query')") | 74 | @PreAuthorize("@ss.hasPermission('promotion:combination-activity:query')") |
| 75 | public CommonResult<CombinationActivityRespVO> getCombinationActivity(@RequestParam("id") Long id) { | 75 | public CommonResult<CombinationActivityRespVO> getCombinationActivity(@RequestParam("id") Long id) { |
| 76 | CombinationActivityDO activity = combinationActivityService.getCombinationActivity(id); | 76 | CombinationActivityDO activity = combinationActivityService.getCombinationActivity(id); |
| 77 | - List<CombinationProductDO> products = combinationActivityService.getCombinationProductsByActivityIds(newArrayList(id)); | 77 | + List<CombinationProductDO> products = combinationActivityService.getCombinationProductListByActivityIds(newArrayList(id)); |
| 78 | return success(CombinationActivityConvert.INSTANCE.convert(activity, products)); | 78 | return success(CombinationActivityConvert.INSTANCE.convert(activity, products)); |
| 79 | } | 79 | } |
| 80 | 80 | ||
| @@ -98,7 +98,7 @@ public class CombinationActivityController { | @@ -98,7 +98,7 @@ public class CombinationActivityController { | ||
| 98 | Map<Long, Integer> recordCountMap = combinationRecordService.getCombinationRecordCountMapByActivity( | 98 | Map<Long, Integer> recordCountMap = combinationRecordService.getCombinationRecordCountMapByActivity( |
| 99 | activityIds, null, null); | 99 | activityIds, null, null); |
| 100 | // 拼接数据 | 100 | // 拼接数据 |
| 101 | - List<CombinationProductDO> products = combinationActivityService.getCombinationProductsByActivityIds( | 101 | + List<CombinationProductDO> products = combinationActivityService.getCombinationProductListByActivityIds( |
| 102 | convertSet(pageResult.getList(), CombinationActivityDO::getId)); | 102 | convertSet(pageResult.getList(), CombinationActivityDO::getId)); |
| 103 | List<ProductSpuRespDTO> spus = productSpuApi.getSpuList( | 103 | List<ProductSpuRespDTO> spus = productSpuApi.getSpuList( |
| 104 | convertSet(pageResult.getList(), CombinationActivityDO::getSpuId)); | 104 | convertSet(pageResult.getList(), CombinationActivityDO::getSpuId)); |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/combination/CombinationRecordController.java
| @@ -78,7 +78,7 @@ public class CombinationRecordController { | @@ -78,7 +78,7 @@ public class CombinationRecordController { | ||
| 78 | 78 | ||
| 79 | private Map<String, Long> getCombinationRecordSummary0() { | 79 | private Map<String, Long> getCombinationRecordSummary0() { |
| 80 | Map<String, Long> hashMap = MapUtil.newHashMap(3); | 80 | Map<String, Long> hashMap = MapUtil.newHashMap(3); |
| 81 | - hashMap.put("userCount", combinationRecordService.getCombinationRecordsCount());// 获取所有拼团记录 | 81 | + hashMap.put("userCount", combinationRecordService.getCombinationRecordCount());// 获取所有拼团记录 |
| 82 | hashMap.put("successCount", combinationRecordService.getCombinationRecordsSuccessCount());// 获取成团记录 | 82 | hashMap.put("successCount", combinationRecordService.getCombinationRecordsSuccessCount());// 获取成团记录 |
| 83 | hashMap.put("virtualGroupCount", combinationRecordService.getRecordsVirtualGroupCount());// 获取虚拟成团记录 | 83 | hashMap.put("virtualGroupCount", combinationRecordService.getRecordsVirtualGroupCount());// 获取虚拟成团记录 |
| 84 | return hashMap; | 84 | return hashMap; |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/combination/AppCombinationActivityController.java
| @@ -30,7 +30,6 @@ import java.time.Duration; | @@ -30,7 +30,6 @@ import java.time.Duration; | ||
| 30 | import java.util.Collections; | 30 | import java.util.Collections; |
| 31 | import java.util.List; | 31 | import java.util.List; |
| 32 | 32 | ||
| 33 | -import static cn.hutool.core.util.ObjectUtil.defaultIfNull; | ||
| 34 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 33 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 35 | import static cn.iocoder.yudao.framework.common.util.cache.CacheUtils.buildAsyncReloadingCache; | 34 | import static cn.iocoder.yudao.framework.common.util.cache.CacheUtils.buildAsyncReloadingCache; |
| 36 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 35 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| @@ -56,6 +55,7 @@ public class AppCombinationActivityController { | @@ -56,6 +55,7 @@ public class AppCombinationActivityController { | ||
| 56 | 55 | ||
| 57 | @Resource | 56 | @Resource |
| 58 | private CombinationActivityService activityService; | 57 | private CombinationActivityService activityService; |
| 58 | + | ||
| 59 | @Resource | 59 | @Resource |
| 60 | private ProductSpuApi spuApi; | 60 | private ProductSpuApi spuApi; |
| 61 | 61 | ||
| @@ -68,40 +68,45 @@ public class AppCombinationActivityController { | @@ -68,40 +68,45 @@ public class AppCombinationActivityController { | ||
| 68 | } | 68 | } |
| 69 | 69 | ||
| 70 | private List<AppCombinationActivityRespVO> getCombinationActivityList0(Integer count) { | 70 | private List<AppCombinationActivityRespVO> getCombinationActivityList0(Integer count) { |
| 71 | - List<CombinationActivityDO> list = activityService.getCombinationActivityListByCount(defaultIfNull(count, 6)); | ||
| 72 | - if (CollUtil.isEmpty(list)) { | 71 | + List<CombinationActivityDO> activityList = activityService.getCombinationActivityListByCount(count); |
| 72 | + if (CollUtil.isEmpty(activityList)) { | ||
| 73 | return Collections.emptyList(); | 73 | return Collections.emptyList(); |
| 74 | } | 74 | } |
| 75 | // 拼接返回 | 75 | // 拼接返回 |
| 76 | - List<ProductSpuRespDTO> spuList = spuApi.getSpuList(convertList(list, CombinationActivityDO::getSpuId)); | ||
| 77 | - return CombinationActivityConvert.INSTANCE.convertAppList(list, spuList); | 76 | + List<CombinationProductDO> productList = activityService.getCombinationProductListByActivityIds( |
| 77 | + convertList(activityList, CombinationActivityDO::getId)); | ||
| 78 | + List<ProductSpuRespDTO> spuList = spuApi.getSpuList(convertList(activityList, CombinationActivityDO::getSpuId)); | ||
| 79 | + return CombinationActivityConvert.INSTANCE.convertAppList(activityList, productList, spuList); | ||
| 78 | } | 80 | } |
| 79 | 81 | ||
| 80 | @GetMapping("/page") | 82 | @GetMapping("/page") |
| 81 | @Operation(summary = "获得拼团活动分页") | 83 | @Operation(summary = "获得拼团活动分页") |
| 82 | public CommonResult<PageResult<AppCombinationActivityRespVO>> getCombinationActivityPage(PageParam pageParam) { | 84 | public CommonResult<PageResult<AppCombinationActivityRespVO>> getCombinationActivityPage(PageParam pageParam) { |
| 83 | - PageResult<CombinationActivityDO> result = activityService.getCombinationActivityPage(pageParam); | ||
| 84 | - if (CollUtil.isEmpty(result.getList())) { | ||
| 85 | - return success(PageResult.empty(result.getTotal())); | 85 | + PageResult<CombinationActivityDO> pageResult = activityService.getCombinationActivityPage(pageParam); |
| 86 | + if (CollUtil.isEmpty(pageResult.getList())) { | ||
| 87 | + return success(PageResult.empty(pageResult.getTotal())); | ||
| 86 | } | 88 | } |
| 87 | // 拼接返回 | 89 | // 拼接返回 |
| 88 | - List<ProductSpuRespDTO> spuList = spuApi.getSpuList(convertList(result.getList(), CombinationActivityDO::getSpuId)); | ||
| 89 | - return success(CombinationActivityConvert.INSTANCE.convertAppPage(result, spuList)); | 90 | + List<CombinationProductDO> productList = activityService.getCombinationProductListByActivityIds( |
| 91 | + convertList(pageResult.getList(), CombinationActivityDO::getId)); | ||
| 92 | + List<ProductSpuRespDTO> spuList = spuApi.getSpuList(convertList(pageResult.getList(), CombinationActivityDO::getSpuId)); | ||
| 93 | + return success(CombinationActivityConvert.INSTANCE.convertAppPage(pageResult, productList, spuList)); | ||
| 90 | } | 94 | } |
| 91 | 95 | ||
| 92 | @GetMapping("/get-detail") | 96 | @GetMapping("/get-detail") |
| 93 | @Operation(summary = "获得拼团活动明细") | 97 | @Operation(summary = "获得拼团活动明细") |
| 94 | @Parameter(name = "id", description = "活动编号", required = true, example = "1024") | 98 | @Parameter(name = "id", description = "活动编号", required = true, example = "1024") |
| 95 | public CommonResult<AppCombinationActivityDetailRespVO> getCombinationActivityDetail(@RequestParam("id") Long id) { | 99 | public CommonResult<AppCombinationActivityDetailRespVO> getCombinationActivityDetail(@RequestParam("id") Long id) { |
| 96 | - // 1、获取活动 | ||
| 97 | - CombinationActivityDO combinationActivity = activityService.getCombinationActivity(id); | ||
| 98 | - if (combinationActivity == null | ||
| 99 | - || ObjectUtil.equal(combinationActivity.getStatus(), CommonStatusEnum.DISABLE.getStatus())) { | 100 | + // 1. 获取活动 |
| 101 | + CombinationActivityDO activity = activityService.getCombinationActivity(id); | ||
| 102 | + if (activity == null | ||
| 103 | + || ObjectUtil.equal(activity.getStatus(), CommonStatusEnum.DISABLE.getStatus())) { | ||
| 100 | return success(null); | 104 | return success(null); |
| 101 | } | 105 | } |
| 102 | - // 2、获取活动商品 | ||
| 103 | - List<CombinationProductDO> products = activityService.getCombinationProductsByActivityId(combinationActivity.getId()); | ||
| 104 | - return success(CombinationActivityConvert.INSTANCE.convert3(combinationActivity, products)); | 106 | + |
| 107 | + // 2. 获取活动商品 | ||
| 108 | + List<CombinationProductDO> products = activityService.getCombinationProductsByActivityId(activity.getId()); | ||
| 109 | + return success(CombinationActivityConvert.INSTANCE.convert3(activity, products)); | ||
| 105 | } | 110 | } |
| 106 | 111 | ||
| 107 | } | 112 | } |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/combination/AppCombinationRecordController.java
| @@ -39,21 +39,21 @@ public class AppCombinationRecordController { | @@ -39,21 +39,21 @@ public class AppCombinationRecordController { | ||
| 39 | 39 | ||
| 40 | @GetMapping("/get-summary") | 40 | @GetMapping("/get-summary") |
| 41 | @Operation(summary = "获得拼团记录的概要信息", description = "用于小程序首页") | 41 | @Operation(summary = "获得拼团记录的概要信息", description = "用于小程序首页") |
| 42 | - // TODO 芋艿:增加 @Cache 缓存,1 分钟过期 | ||
| 43 | public CommonResult<AppCombinationRecordSummaryRespVO> getCombinationRecordSummary() { | 42 | public CommonResult<AppCombinationRecordSummaryRespVO> getCombinationRecordSummary() { |
| 44 | - // 获取所有拼团记录 | ||
| 45 | - Long count = combinationRecordService.getCombinationRecordsCount(); | ||
| 46 | AppCombinationRecordSummaryRespVO summary = new AppCombinationRecordSummaryRespVO(); | 43 | AppCombinationRecordSummaryRespVO summary = new AppCombinationRecordSummaryRespVO(); |
| 47 | - if (count == null || count == 0L) { | 44 | + // 1. 获得拼团记录数量 |
| 45 | + Long count = combinationRecordService.getCombinationRecordCount(); | ||
| 46 | + if (count == 0) { | ||
| 48 | summary.setAvatars(Collections.emptyList()); | 47 | summary.setAvatars(Collections.emptyList()); |
| 49 | summary.setUserCount(count); | 48 | summary.setUserCount(count); |
| 50 | return success(summary); | 49 | return success(summary); |
| 51 | } | 50 | } |
| 52 | - | ||
| 53 | summary.setUserCount(count); | 51 | summary.setUserCount(count); |
| 54 | - // TODO 只返回最近的 7 个 | ||
| 55 | - int num = 7; | ||
| 56 | - summary.setAvatars(convertList(combinationRecordService.getLatestCombinationRecordList(num), CombinationRecordDO::getAvatar)); | 52 | + |
| 53 | + // 2. 获得拼团记录头像 | ||
| 54 | + List<CombinationRecordDO> records = combinationRecordService.getLatestCombinationRecordList( | ||
| 55 | + AppCombinationRecordSummaryRespVO.AVATAR_COUNT); | ||
| 56 | + summary.setAvatars(convertList(records, CombinationRecordDO::getAvatar)); | ||
| 57 | return success(summary); | 57 | return success(summary); |
| 58 | } | 58 | } |
| 59 | 59 |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/combination/vo/record/AppCombinationRecordSummaryRespVO.java
| @@ -9,6 +9,11 @@ import java.util.List; | @@ -9,6 +9,11 @@ import java.util.List; | ||
| 9 | @Data | 9 | @Data |
| 10 | public class AppCombinationRecordSummaryRespVO { | 10 | public class AppCombinationRecordSummaryRespVO { |
| 11 | 11 | ||
| 12 | + /** | ||
| 13 | + * 加载 {@link #avatars} 的数量 | ||
| 14 | + */ | ||
| 15 | + public static final Integer AVATAR_COUNT = 7; | ||
| 16 | + | ||
| 12 | @Schema(description = "拼团用户数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") | 17 | @Schema(description = "拼团用户数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| 13 | private Long userCount; | 18 | private Long userCount; |
| 14 | 19 |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/seckill/AppSeckillActivityController.java
| @@ -86,7 +86,8 @@ public class AppSeckillActivityController { | @@ -86,7 +86,8 @@ public class AppSeckillActivityController { | ||
| 86 | 86 | ||
| 87 | // 2.1 查询满足当前阶段的活动 | 87 | // 2.1 查询满足当前阶段的活动 |
| 88 | List<SeckillActivityDO> activityList = activityService.getSeckillActivityListByConfigIdAndStatus(config.getId(), CommonStatusEnum.ENABLE.getStatus()); | 88 | List<SeckillActivityDO> activityList = activityService.getSeckillActivityListByConfigIdAndStatus(config.getId(), CommonStatusEnum.ENABLE.getStatus()); |
| 89 | - List<SeckillProductDO> productList = activityService.getSeckillProductListByActivityId(convertList(activityList, SeckillActivityDO::getId)); | 89 | + List<SeckillProductDO> productList = activityService.getSeckillProductListByActivityId( |
| 90 | + convertList(activityList, SeckillActivityDO::getId)); | ||
| 90 | // 2.2 获取 spu 信息 | 91 | // 2.2 获取 spu 信息 |
| 91 | List<ProductSpuRespDTO> spuList = spuApi.getSpuList(convertList(activityList, SeckillActivityDO::getSpuId)); | 92 | List<ProductSpuRespDTO> spuList = spuApi.getSpuList(convertList(activityList, SeckillActivityDO::getSpuId)); |
| 92 | return SeckillActivityConvert.INSTANCE.convert(config, activityList, productList, spuList); | 93 | return SeckillActivityConvert.INSTANCE.convert(config, activityList, productList, spuList); |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/convert/combination/CombinationActivityConvert.java
| @@ -28,7 +28,7 @@ import org.mapstruct.factory.Mappers; | @@ -28,7 +28,7 @@ import org.mapstruct.factory.Mappers; | ||
| 28 | import java.util.List; | 28 | import java.util.List; |
| 29 | import java.util.Map; | 29 | import java.util.Map; |
| 30 | 30 | ||
| 31 | -import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMap; | 31 | +import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 32 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; | 32 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; |
| 33 | 33 | ||
| 34 | /** | 34 | /** |
| @@ -120,10 +120,16 @@ public interface CombinationActivityConvert { | @@ -120,10 +120,16 @@ public interface CombinationActivityConvert { | ||
| 120 | 120 | ||
| 121 | List<AppCombinationActivityRespVO> convertAppList(List<CombinationActivityDO> list); | 121 | List<AppCombinationActivityRespVO> convertAppList(List<CombinationActivityDO> list); |
| 122 | 122 | ||
| 123 | - default List<AppCombinationActivityRespVO> convertAppList(List<CombinationActivityDO> list, List<ProductSpuRespDTO> spuList) { | 123 | + default List<AppCombinationActivityRespVO> convertAppList(List<CombinationActivityDO> list, |
| 124 | + List<CombinationProductDO> productList, | ||
| 125 | + List<ProductSpuRespDTO> spuList) { | ||
| 124 | List<AppCombinationActivityRespVO> activityList = convertAppList(list); | 126 | List<AppCombinationActivityRespVO> activityList = convertAppList(list); |
| 125 | Map<Long, ProductSpuRespDTO> spuMap = convertMap(spuList, ProductSpuRespDTO::getId); | 127 | Map<Long, ProductSpuRespDTO> spuMap = convertMap(spuList, ProductSpuRespDTO::getId); |
| 128 | + Map<Long, List<CombinationProductDO>> productMap = convertMultiMap(productList, CombinationProductDO::getActivityId); | ||
| 126 | return CollectionUtils.convertList(activityList, item -> { | 129 | return CollectionUtils.convertList(activityList, item -> { |
| 130 | + // 设置 product 信息 | ||
| 131 | + item.setCombinationPrice(getMinValue(productMap.get(item.getId()), CombinationProductDO::getCombinationPrice)); | ||
| 132 | + // 设置 SPU 信息 | ||
| 127 | findAndThen(spuMap, item.getSpuId(), spu -> item.setPicUrl(spu.getPicUrl()).setMarketPrice(spu.getMarketPrice())); | 133 | findAndThen(spuMap, item.getSpuId(), spu -> item.setPicUrl(spu.getPicUrl()).setMarketPrice(spu.getMarketPrice())); |
| 128 | return item; | 134 | return item; |
| 129 | }); | 135 | }); |
| @@ -131,13 +137,17 @@ public interface CombinationActivityConvert { | @@ -131,13 +137,17 @@ public interface CombinationActivityConvert { | ||
| 131 | 137 | ||
| 132 | PageResult<AppCombinationActivityRespVO> convertAppPage(PageResult<CombinationActivityDO> result); | 138 | PageResult<AppCombinationActivityRespVO> convertAppPage(PageResult<CombinationActivityDO> result); |
| 133 | 139 | ||
| 134 | - default PageResult<AppCombinationActivityRespVO> convertAppPage(PageResult<CombinationActivityDO> result, List<ProductSpuRespDTO> spuList) { | 140 | + default PageResult<AppCombinationActivityRespVO> convertAppPage(PageResult<CombinationActivityDO> result, |
| 141 | + List<CombinationProductDO> productList, | ||
| 142 | + List<ProductSpuRespDTO> spuList) { | ||
| 135 | PageResult<AppCombinationActivityRespVO> appPage = convertAppPage(result); | 143 | PageResult<AppCombinationActivityRespVO> appPage = convertAppPage(result); |
| 136 | Map<Long, ProductSpuRespDTO> spuMap = convertMap(spuList, ProductSpuRespDTO::getId); | 144 | Map<Long, ProductSpuRespDTO> spuMap = convertMap(spuList, ProductSpuRespDTO::getId); |
| 145 | + Map<Long, List<CombinationProductDO>> productMap = convertMultiMap(productList, CombinationProductDO::getActivityId); | ||
| 137 | List<AppCombinationActivityRespVO> list = CollectionUtils.convertList(appPage.getList(), item -> { | 146 | List<AppCombinationActivityRespVO> list = CollectionUtils.convertList(appPage.getList(), item -> { |
| 138 | - findAndThen(spuMap, item.getSpuId(), spu -> { | ||
| 139 | - item.setPicUrl(spu.getPicUrl()).setMarketPrice(spu.getMarketPrice()); | ||
| 140 | - }); | 147 | + // 设置 product 信息 |
| 148 | + item.setCombinationPrice(getMinValue(productMap.get(item.getId()), CombinationProductDO::getCombinationPrice)); | ||
| 149 | + // 设置 SPU 信息 | ||
| 150 | + findAndThen(spuMap, item.getSpuId(), spu -> item.setPicUrl(spu.getPicUrl()).setMarketPrice(spu.getMarketPrice())); | ||
| 141 | return item; | 151 | return item; |
| 142 | }); | 152 | }); |
| 143 | appPage.setList(list); | 153 | appPage.setList(list); |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/dal/mysql/combination/CombinationRecordMapper.java
| @@ -77,7 +77,7 @@ public interface CombinationRecordMapper extends BaseMapperX<CombinationRecordDO | @@ -77,7 +77,7 @@ public interface CombinationRecordMapper extends BaseMapperX<CombinationRecordDO | ||
| 77 | */ | 77 | */ |
| 78 | default List<CombinationRecordDO> selectLatestList(int count) { | 78 | default List<CombinationRecordDO> selectLatestList(int count) { |
| 79 | return selectList(new LambdaQueryWrapperX<CombinationRecordDO>() | 79 | return selectList(new LambdaQueryWrapperX<CombinationRecordDO>() |
| 80 | - .orderByDesc(CombinationRecordDO::getCreateTime) | 80 | + .orderByDesc(CombinationRecordDO::getId) |
| 81 | .last("LIMIT " + count)); | 81 | .last("LIMIT " + count)); |
| 82 | } | 82 | } |
| 83 | 83 |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/service/combination/CombinationActivityService.java
| @@ -73,7 +73,7 @@ public interface CombinationActivityService { | @@ -73,7 +73,7 @@ public interface CombinationActivityService { | ||
| 73 | * @return 拼团活动的商品列表 | 73 | * @return 拼团活动的商品列表 |
| 74 | */ | 74 | */ |
| 75 | default List<CombinationProductDO> getCombinationProductsByActivityId(Long activityId) { | 75 | default List<CombinationProductDO> getCombinationProductsByActivityId(Long activityId) { |
| 76 | - return getCombinationProductsByActivityIds(Collections.singletonList(activityId)); | 76 | + return getCombinationProductListByActivityIds(Collections.singletonList(activityId)); |
| 77 | } | 77 | } |
| 78 | 78 | ||
| 79 | /** | 79 | /** |
| @@ -82,7 +82,7 @@ public interface CombinationActivityService { | @@ -82,7 +82,7 @@ public interface CombinationActivityService { | ||
| 82 | * @param activityIds 拼团活动 ids | 82 | * @param activityIds 拼团活动 ids |
| 83 | * @return 拼团活动的商品列表 | 83 | * @return 拼团活动的商品列表 |
| 84 | */ | 84 | */ |
| 85 | - List<CombinationProductDO> getCombinationProductsByActivityIds(Collection<Long> activityIds); | 85 | + List<CombinationProductDO> getCombinationProductListByActivityIds(Collection<Long> activityIds); |
| 86 | 86 | ||
| 87 | /** | 87 | /** |
| 88 | * 获取正在进行的活动分页数据 | 88 | * 获取正在进行的活动分页数据 |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/service/combination/CombinationActivityServiceImpl.java
| @@ -200,7 +200,7 @@ public class CombinationActivityServiceImpl implements CombinationActivityServic | @@ -200,7 +200,7 @@ public class CombinationActivityServiceImpl implements CombinationActivityServic | ||
| 200 | } | 200 | } |
| 201 | 201 | ||
| 202 | @Override | 202 | @Override |
| 203 | - public List<CombinationProductDO> getCombinationProductsByActivityIds(Collection<Long> activityIds) { | 203 | + public List<CombinationProductDO> getCombinationProductListByActivityIds(Collection<Long> activityIds) { |
| 204 | return combinationProductMapper.selectListByActivityIds(activityIds); | 204 | return combinationProductMapper.selectListByActivityIds(activityIds); |
| 205 | } | 205 | } |
| 206 | 206 |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/service/combination/CombinationRecordService.java
| @@ -96,7 +96,7 @@ public interface CombinationRecordService { | @@ -96,7 +96,7 @@ public interface CombinationRecordService { | ||
| 96 | * | 96 | * |
| 97 | * @return 记录数 | 97 | * @return 记录数 |
| 98 | */ | 98 | */ |
| 99 | - Long getCombinationRecordsCount(); | 99 | + Long getCombinationRecordCount(); |
| 100 | 100 | ||
| 101 | /** | 101 | /** |
| 102 | * 获取成功记录数 | 102 | * 获取成功记录数 |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/service/combination/CombinationRecordServiceImpl.java
| @@ -227,7 +227,7 @@ public class CombinationRecordServiceImpl implements CombinationRecordService { | @@ -227,7 +227,7 @@ public class CombinationRecordServiceImpl implements CombinationRecordService { | ||
| 227 | } | 227 | } |
| 228 | 228 | ||
| 229 | @Override | 229 | @Override |
| 230 | - public Long getCombinationRecordsCount() { | 230 | + public Long getCombinationRecordCount() { |
| 231 | return recordMapper.selectCount(); | 231 | return recordMapper.selectCount(); |
| 232 | } | 232 | } |
| 233 | 233 |