Class TmaSubscriptionPageController
java.lang.Object
de.hybris.platform.addonsupport.controllers.AbstractAddOnController
de.hybris.platform.addonsupport.controllers.page.AbstractAddOnPageController
de.hybris.platform.b2ctelcoaddon.controllers.pages.AbstractSearchPageController
de.hybris.platform.b2ctelcoaddon.controllers.pages.TmaSubscriptionPageController
@Controller
@RequestMapping("/my-account/subscription")
public class TmaSubscriptionPageController
extends AbstractSearchPageController
Controller for home page.
-
Nested Class Summary
Nested classes/interfaces inherited from class de.hybris.platform.b2ctelcoaddon.controllers.pages.AbstractSearchPageController
AbstractSearchPageController.SearchResultsData<RESULT>, AbstractSearchPageController.ShowModeNested classes/interfaces inherited from class de.hybris.platform.addonsupport.controllers.AbstractAddOnController
de.hybris.platform.addonsupport.controllers.AbstractAddOnController.HttpNotFoundException -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected de.hybris.platform.commercefacades.user.UserFacadeFields inherited from class de.hybris.platform.b2ctelcoaddon.controllers.pages.AbstractSearchPageController
MAX_PAGE_LIMITFields inherited from class de.hybris.platform.addonsupport.controllers.page.AbstractAddOnPageController
CMS_PAGE_MODEL, CMS_PAGE_TITLE, PAGE_ROOTFields inherited from class de.hybris.platform.addonsupport.controllers.AbstractAddOnController
FORWARD_PREFIX, REDIRECT_PREFIX, ROOT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncancelsubscription(String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for Canceling subscription.changeSubscriptionState(String newState, String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for changing state of subscription.extendSubscriptionTermDuration(Integer contractDurationExtension, String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for extending TMAservice's Term for duration.protected TmaProductOfferFacadereplaceSubscriptionPaymentMethod(String paymentMethodId, String subscriptionId, String effectiveFrom, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for updating default payment of TMAservice.setAutorenewalStatus(boolean autorenew, String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for updating sAutorenewalStatus state of subscription.subscription(String subscriptionId, String actionVal, org.springframework.ui.Model model) Get method finds available subscription details for loggedin user for manage subscription Page.subscriptionBaseServices(String billingSystemId, String subscriberIdentity, org.springframework.ui.Model model) Get method finds available subscription-base details for loggedin user for show related service details.subscriptions(org.springframework.ui.Model model) subscriptions is get method.It finds available subscriptions, paymentInfoMap, Breadcrum for loggedin user.upgradesubscription(String productCode, String subscriptionId, org.springframework.ui.Model model, long qty, String subscriberId, String subscriberBillingId, String rootBpoCode, int cartGroupNo, String subscriptionTermId) This Post method responsible for upgrading subscription.upgradeSubscriptionComparison(String subscriptionId, org.springframework.ui.Model model) This Get method responsible for loading upgrading option for subsription.viewSubscriptionBillingActivity(String subscriptionId, org.springframework.ui.Model model) This get method show billing acitvity of user.Methods inherited from class de.hybris.platform.b2ctelcoaddon.controllers.pages.AbstractSearchPageController
calculateShowAll, calculateShowPaged, convertBreadcrumbsToFacets, createPageableData, existsFacetValueWithName, getMaxSearchPageSize, getSearchPageSize, isShowAllAllowed, populateModel, refineFacetsMethods inherited from class de.hybris.platform.addonsupport.controllers.page.AbstractAddOnPageController
checkRequestUrl, createMetaElement, getCmsPageService, getCmsSiteService, getContentPageForLabelOrId, getCurrencies, getCurrentCurrency, getCurrentLanguage, getCustomerFacade, getHostConfigService, getI18nService, getLanguages, getMessageSource, getPageTitleResolver, getRequestContextData, getSessionService, getSiteConfigService, getSiteName, getStoreSessionFacade, getUser, getViewForPage, getViewForPage, setUpMetaData, setUpMetaDataForContentPage, storeCmsPageInModel, storeContentPageTitleInModel, storeContinueUrlMethods inherited from class de.hybris.platform.addonsupport.controllers.AbstractAddOnController
addRequestToModel, getBean
-
Field Details
-
userFacade
protected de.hybris.platform.commercefacades.user.UserFacade userFacade
-
-
Constructor Details
-
TmaSubscriptionPageController
public TmaSubscriptionPageController()
-
-
Method Details
-
subscriptions
@RequestMapping(method=GET) public String subscriptions(@Nonnull org.springframework.ui.Model model) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException subscriptions is get method.It finds available subscriptions, paymentInfoMap, Breadcrum for loggedin user.- Returns:
- Throws:
de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
-
subscription
@RequestMapping(value="/{subscriptionId:.*}/{actionVal}", method=GET) public String subscription(@PathVariable("subscriptionId") String subscriptionId, @PathVariable("actionVal") String actionVal, org.springframework.ui.Model model) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException Get method finds available subscription details for loggedin user for manage subscription Page.- Parameters:
subscriptionId- Subscription IDactionVal- manage or details- Returns:
- Throws:
de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
-
subscriptionBaseServices
@RequestMapping(value="/subscription-base/{billingSystemId}/{subscriberIdentity}", method=GET) public String subscriptionBaseServices(@Nonnull @PathVariable(value="billingSystemId",required=true) String billingSystemId, @Nonnull @PathVariable(value="subscriberIdentity",required=true) String subscriberIdentity, @Nonnull org.springframework.ui.Model model) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException Get method finds available subscription-base details for loggedin user for show related service details.- Parameters:
billingSystemId- ID of billing systemsubscriberIdentity- ID of TmaSubscriptionBase- Returns:
- Throws:
de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
-
extendSubscriptionTermDuration
@RequestMapping(value="/extend-term-duration", method=POST) public String extendSubscriptionTermDuration(@RequestParam(value="contractDurationExtension",required=true) Integer contractDurationExtension, @RequestParam(value="subscriptionId",required=true) String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for extending TMAservice's Term for duration.- Parameters:
contractDurationExtension- Integer value for which contract need to be extendedsubscriptionId- Id for subscription for with terms need to be extended- Returns:
-
upgradeSubscriptionComparison
@RequestMapping(value="/upgrades-comparison", method=GET) public String upgradeSubscriptionComparison(@Nonnull @RequestParam("subscriptionId") String subscriptionId, @Nonnull org.springframework.ui.Model model) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException This Get method responsible for loading upgrading option for subsription.- Parameters:
subscriptionId- Id for subscription for with terms need to be extended- Returns:
- Throws:
de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
-
upgradesubscription
@RequestMapping(value="/upgrade", method=POST) public String upgradesubscription(@RequestParam(value="productCode",required=true) String productCode, @RequestParam(value="subscriptionId",required=true) String subscriptionId, org.springframework.ui.Model model, @RequestParam(value="qty",required=false,defaultValue="1") long qty, @RequestParam(value="subscriberId",required=true) String subscriberId, @RequestParam(value="subscriberBillingId",required=true) String subscriberBillingId, @RequestParam(value="rootBpoCode",required=false) String rootBpoCode, @RequestParam(value="cartGroupNo",required=false,defaultValue="-1") int cartGroupNo, @RequestParam(value="subscriptionTermId",required=true) String subscriptionTermId) This Post method responsible for upgrading subscription.- Parameters:
subscriptionId- Id for subscription for with terms need to be extendedoriginalOrderCode-originalEntryNumber-- Returns:
-
changeSubscriptionState
@RequestMapping(value="/change-state", method=POST) public String changeSubscriptionState(@RequestParam(value="newState",required=true) String newState, @RequestParam(value="subscriptionId",required=true) String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for changing state of subscription.- Parameters:
newState-subscriptionId- Id for subscription for with terms need to be extended- Returns:
-
setAutorenewalStatus
@RequestMapping(value="/set-autorenewal-status", method=POST) public String setAutorenewalStatus(@RequestParam(value="autorenew",required=true) boolean autorenew, @RequestParam(value="subscriptionId",required=true) String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for updating sAutorenewalStatus state of subscription.- Parameters:
autorenew-subscriptionId- Id for subscription for with terms need to be extended- Returns:
-
cancelsubscription
@RequestMapping(value="/cancel/{subscriptionId:.*}", method=GET) public String cancelsubscription(@PathVariable("subscriptionId") String subscriptionId, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for Canceling subscription.- Parameters:
subscriptionId- Id for subscription for with terms need to be extended- Returns:
-
viewSubscriptionBillingActivity
@RequestMapping(value="/billing-activity", method=GET) public String viewSubscriptionBillingActivity(@RequestParam(value="subscriptionId",required=true) String subscriptionId, org.springframework.ui.Model model) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException This get method show billing acitvity of user.- Parameters:
subscriptionId- ID of TmaService- Throws:
de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
-
replaceSubscriptionPaymentMethod
@RequestMapping(value="/billing-activity/payment-method/replace", method=POST) public String replaceSubscriptionPaymentMethod(@RequestParam(value="paymentMethodId",required=true) String paymentMethodId, @RequestParam(value="subscriptionId",required=true) String subscriptionId, @RequestParam(value="effectiveFrom",required=true) String effectiveFrom, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectAttributes) This Post method responsible for updating default payment of TMAservice.- Parameters:
paymentMethodId- Sting value for service need to be updatedsubscriptionId- Id for subscription for with terms need to be extendedeffectiveFrom- Date from which it will be effective- Returns:
-
getTmaProductOfferFacade
-