|
|
|
@ -21,6 +21,25 @@ public class CouponController extends BaseController<CouponService, Coupon>{
|
|
|
|
|
return super.getBaseService();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 看有没有领取过优惠券
|
|
|
|
|
*/
|
|
|
|
|
@RequestMapping(value = "/is-receive-coupon")
|
|
|
|
|
@ResponseBody
|
|
|
|
|
public AjaxResult isReceiveCoupon(@RequestBody AjaxRequest ajaxRequest){
|
|
|
|
|
AjaxResult ajaxResult = new AjaxResult();
|
|
|
|
|
try {
|
|
|
|
|
ajaxResult = couponService.isReceiveCoupon(ajaxRequest);
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
e.printStackTrace();
|
|
|
|
|
String errMsg = e.getMessage() != null ? e.getMessage() : "操作失败";
|
|
|
|
|
ajaxResult.setRetcode(AjaxResult.FAILED);
|
|
|
|
|
ajaxResult.setRetmsg(errMsg);
|
|
|
|
|
}
|
|
|
|
|
return ajaxResult;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 领取优惠券
|
|
|
|
|
*/
|
|
|
|
|