|
|
|
@@ -83,4 +83,27 @@ public class WxCouponOrderController extends BaseController { |
|
|
|
|
|
|
|
return new ResultData(res); |
|
|
|
} |
|
|
|
|
|
|
|
//// ------ 卡相关接口 |
|
|
|
@ApiOperation("卡包分页列表接口") |
|
|
|
@GetMapping("cardList") |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "pageNum", value = "页数", dataType = "int", paramType = "query", required = true), |
|
|
|
@ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "int", paramType = "query", required = true), |
|
|
|
}) |
|
|
|
public ResultData cardList(@ModelAttribute WxCouponOrder wxCouponOrder, Integer pageNum, Integer pageSize) { |
|
|
|
|
|
|
|
if (pageNum == null || pageSize == null) { |
|
|
|
return new ResultData(ErrorCode.SYS_PARAMETER_NOT_NULL); |
|
|
|
} |
|
|
|
if (wxCouponOrder == null) wxCouponOrder = new WxCouponOrderCVo(); |
|
|
|
wxCouponOrder.setCUserId(getUser().getId()); |
|
|
|
if (wxCouponOrder.getCouponOrderStatus() == null) |
|
|
|
wxCouponOrder.setSortColumns(WxCouponOrder.Field.CreateDate_DESC); |
|
|
|
else if (wxCouponOrder.getCouponOrderStatus() == EnumCouponOrderStatus.COUPON_ORDER_USE_WAIT.getCode()) |
|
|
|
wxCouponOrder.setSortColumns(WxCouponOrder.Field.CreateDate_DESC); |
|
|
|
else |
|
|
|
wxCouponOrder.setSortColumns(WxCouponOrder.Field.UpdateDate_DESC); |
|
|
|
return wxCouponOrderService.listCUserVoAsPage(wxCouponOrder, pageNum, pageSize); |
|
|
|
} |
|
|
|
} |