Class CustomerCouponsController
java.lang.Object
de.hybris.platform.customercouponocc.controllers.customercoupon.CustomerCouponsController
@Controller
@RequestMapping("/{baseSiteId}/users/{userId}/customercoupons")
public class CustomerCouponsController
extends Object
APIs for my coupons.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoClaimCustomerCoupon(String couponCode, String fields) doSubscribeToCustomerCoupon(String couponCode, String fields) voiddoUnsubscribeFromCustomerCoupon(String couponCode) protected CustomerCouponFacadegetCustomerCoupons(int currentPage, int pageSize, String sort, boolean needsTotal, String fields) protected CustomerFacadeprotected UserWsDTOgetCustomerWsDTO(String fields) protected DataMapperprotected WebPaginationUtilsprotected voidrecalculatePageSize(SearchPageData searchPageData) protected voidvalidateCoupon(org.springframework.validation.Validator validator, Object obj, String objName)
-
Constructor Details
-
CustomerCouponsController
public CustomerCouponsController()
-
-
Method Details
-
getCustomerCoupons
@Secured({"ROLE_CUSTOMERGROUP","ROLE_CUSTOMERMANAGERGROUP","ROLE_TRUSTED_CLIENT"}) @ResponseBody @GetMapping public CustomerCouponSearchResultWsDTO getCustomerCoupons(@RequestParam(name="currentPage",required=false,defaultValue="0") int currentPage, @RequestParam(name="pageSize",required=false,defaultValue="10") int pageSize, @RequestParam(name="sort",required=false) String sort, @RequestParam(name="needsTotal",required=false,defaultValue="true") boolean needsTotal, @RequestParam(defaultValue="DEFAULT") String fields) -
doClaimCustomerCoupon
@Secured({"ROLE_CUSTOMERGROUP","ROLE_CUSTOMERMANAGERGROUP","ROLE_TRUSTED_CLIENT"}) @PostMapping("/{couponCode}/claim") @ResponseStatus(CREATED) @ResponseBody public CustomerCoupon2CustomerWsDTO doClaimCustomerCoupon(@PathVariable String couponCode, @RequestParam(defaultValue="DEFAULT") String fields) -
doSubscribeToCustomerCoupon
@Secured({"ROLE_CUSTOMERGROUP","ROLE_CUSTOMERMANAGERGROUP","ROLE_TRUSTED_CLIENT"}) @PostMapping("/{couponCode}/notification") @ResponseStatus(CREATED) @ResponseBody public CustomerCouponNotificationWsDTO doSubscribeToCustomerCoupon(@PathVariable String couponCode, @RequestParam(defaultValue="DEFAULT") String fields) -
doUnsubscribeFromCustomerCoupon
@Secured({"ROLE_CUSTOMERGROUP","ROLE_CUSTOMERMANAGERGROUP","ROLE_TRUSTED_CLIENT"}) @ResponseStatus(code=OK) @DeleteMapping("/{couponCode}/notification") public void doUnsubscribeFromCustomerCoupon(@PathVariable String couponCode) -
validateCoupon
-
recalculatePageSize
-
getCustomerWsDTO
-
getCustomerCouponFacade
-
getDataMapper
-
getCustomerNotificationPreferenceCheckStrategy
protected CustomerNotificationPreferenceCheckStrategy getCustomerNotificationPreferenceCheckStrategy() -
getWebPaginationUtils
-
getCustomerFacade
-