@Controller @RequestMapping("/login") public class CmsLoginPageController extends AbstractLoginPageController
Login Controller. Handles login and register for the account flow.
  • Field Details

    • cmsConsentFacade

      protected CustomerMasterConsentFacade cmsConsentFacade
    • baseStoreService

      protected de.hybris.platform.store.services.BaseStoreService baseStoreService
  • Constructor Details

    • CmsLoginPageController

      public CmsLoginPageController()
  • Method Details

    • getView

      protected String getView()
      Specified by:
      getView in class AbstractRegisterPageController
    • getSuccessRedirect

      protected String getSuccessRedirect(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
      Specified by:
      getSuccessRedirect in class AbstractRegisterPageController
    • getCmsPage

      protected AbstractPageModel getCmsPage() throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
      Specified by:
      getCmsPage in class AbstractRegisterPageController
      Throws:
      de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
    • doLogin

      @RequestMapping(method=GET) public String doLogin(@RequestHeader(value="referer",required=false) String referer, @RequestParam(value="error",defaultValue="false") boolean loginError, org.springframework.ui.Model model, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, javax.servlet.http.HttpSession session) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
      Throws:
      de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
    • storeReferer

      protected void storeReferer(String referer, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
    • doRegister

      @RequestMapping(value="/register", method=POST) public String doRegister(@RequestHeader(value="referer",required=false) String referer, RegisterForm form, org.springframework.validation.BindingResult bindingResult, org.springframework.ui.Model model, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectModel) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
      Throws:
      de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
    • getTermsAndConditions

      @RequestMapping(value="/register/termsandconditions", method=GET) public String getTermsAndConditions(org.springframework.ui.Model model) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
      Throws:
      de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
    • processRegisterUserRequest

      protected String processRegisterUserRequest(ConsentForm consentForm, String email, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, org.springframework.web.servlet.mvc.support.RedirectAttributes redirectModel) throws de.hybris.platform.cms2.exceptions.CMSItemNotFoundException
      This method takes data from the registration form and create a new customer account and attempts to log in using the credentials of this new user.
      Returns:
      true if there are no binding errors or the account does not already exists.
      Throws:
      de.hybris.platform.cms2.exceptions.CMSItemNotFoundException