!25 fix seckill get error
Merge pull request !25 from OceansDeep/feature/pg
This commit is contained in:
commit
19ab3789e5
@ -1,13 +1,13 @@
|
||||
package cn.lili.controller.promotion;
|
||||
|
||||
import cn.lili.common.enums.PromotionTypeEnum;
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.exception.ServiceException;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.exception.ServiceException;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.promotion.entity.dos.Pintuan;
|
||||
import cn.lili.modules.promotion.entity.dto.PromotionGoodsDTO;
|
||||
import cn.lili.common.enums.PromotionTypeEnum;
|
||||
import cn.lili.modules.promotion.entity.vos.PintuanSearchParams;
|
||||
import cn.lili.modules.promotion.entity.vos.PintuanVO;
|
||||
import cn.lili.modules.promotion.entity.vos.PromotionGoodsSearchParams;
|
||||
@ -39,7 +39,7 @@ public class PintuanManagerController {
|
||||
@GetMapping(value = "/{id}")
|
||||
@ApiOperation(value = "通过id获取")
|
||||
public ResultMessage<Pintuan> get(@PathVariable String id) {
|
||||
Pintuan pintuan = pintuanService.getById(id);
|
||||
Pintuan pintuan = pintuanService.getPintuanByIdFromMongo(id);
|
||||
return ResultUtil.data(pintuan);
|
||||
}
|
||||
|
||||
|
@ -50,14 +50,14 @@ public class SeckillManagerController {
|
||||
@ApiImplicitParam(name = "id", value = "秒杀活动ID", required = true, dataType = "String", paramType = "path")
|
||||
@GetMapping(value = "/{id}")
|
||||
public ResultMessage<Seckill> get(@PathVariable String id) {
|
||||
Seckill seckill = seckillService.getById(id);
|
||||
Seckill seckill = seckillService.getSeckillByIdFromMongo(id);
|
||||
return ResultUtil.data(seckill);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "分页查询秒杀活动列表")
|
||||
@GetMapping
|
||||
public ResultMessage<IPage<Seckill>> getAll(SeckillSearchParams param, PageVO pageVo) {
|
||||
return ResultUtil.data(seckillService.getSeckillByPageFromMysql(param, pageVo));
|
||||
public ResultMessage<IPage<SeckillVO>> getAll(SeckillSearchParams param, PageVO pageVo) {
|
||||
return ResultUtil.data(seckillService.getSeckillByPageFromMongo(param, pageVo));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "删除一个秒杀活动")
|
||||
|
Loading…
x
Reference in New Issue
Block a user