Compare commits

..

No commits in common. "00551ec8fedb893f0ca99fdd4b7ead1507338b5d" and "8fc219ad38557ae4abe611205b1c83924e555b45" have entirely different histories.

View File

@ -130,19 +130,16 @@ public class AppSeckillActivityController {
@GetMapping("/spuList")
@Parameter(name = "count", description = "需要展示的数量", example = "6")
@Operation(summary = "获得秒杀活动分页")
@Operation(summary = "获得现在进行的秒杀活动分页")
public CommonResult<List<ProductSpuRespDTO>> getSeckillActivitySupList(@RequestParam(name = "count", defaultValue = "3") Integer count) {
AppSeckillActivityPageReqVO pageReqVO = new AppSeckillActivityPageReqVO();
Page<SeckillActivityDO> page = new Page<>(1, 3);
;
if (count != null && count != 0) {
pageReqVO.setPageNo(1);
pageReqVO.setPageSize(count);
page = new Page<>(1, count);
}
// Page<SeckillActivityDO> page = new Page<>(1, 3);
// if (count != null && count != 0) {
// page = new Page<>(1, count);
// }
// 先找出当前时间对应的配置时间段id
/* List<Long> configIdList = new ArrayList<>();
List<Long> configIdList = new ArrayList<>();
try {
List<SeckillConfigDO> timeList = configService.getSeckillConfigListByStatus(CommonStatusEnum.ENABLE.getStatus());
SimpleDateFormat format = new SimpleDateFormat("HH:mm");
@ -162,9 +159,9 @@ public class AppSeckillActivityController {
return success(null);
}
// 获取满足当前正在进行的活动
PageResult<SeckillActivityDO> pageResult = activityService.getRunningActivityByConfigIdsCount(configIdList, page);*/
PageResult<SeckillActivityDO> pageResult = activityService.getRunningActivityByConfigIdsCount(configIdList, page);
// 1. 查询满足当前阶段的活动
PageResult<SeckillActivityDO> pageResult = activityService.getSeckillActivityAppPageByConfigId(pageReqVO);
// PageResult<SeckillActivityDO> pageResult = activityService.getSeckillActivityAppPageByConfigId(pageReqVO);
if (CollUtil.isEmpty(pageResult.getList())) {
return success(null);
}