From 83c15b740c098f258e1abdbd7508e02020cafd28 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Thu, 16 Jun 2016 16:04:49 +0200 Subject: [PATCH] fixed template "base path" (please cherry-pick this) MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../login/PizzaUserLoginWebSessionBean.java | 42 ++++++++++++------- 1 file changed, 26 insertions(+), 16 deletions(-) diff --git a/src/java/org/mxchange/pizzaapplication/beans/login/PizzaUserLoginWebSessionBean.java b/src/java/org/mxchange/pizzaapplication/beans/login/PizzaUserLoginWebSessionBean.java index cab8d936..5f59aabd 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/login/PizzaUserLoginWebSessionBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/login/PizzaUserLoginWebSessionBean.java @@ -51,11 +51,27 @@ import org.mxchange.pizzaapplication.beans.user.PizzaUserWebSessionController; @SessionScoped public class PizzaUserLoginWebSessionBean extends BasePizzaController implements PizzaUserLoginWebSessionController { + /** + * Path name for guest base template + */ + private static final String GUEST_BASE_TEMPLATE_NAME = "guest/guest"; + + /** + * Path name for logged-in user base template + */ + private static final String USER_BASE_TEMPLATE_NAME = "login/user/user"; + /** * Serial number */ private static final long serialVersionUID = 47_828_986_719_691_592L; + /** + * Template type for pages that might be displayed in guest area and login + * area. + */ + private String baseTemplatePathName; + /** * Current password */ @@ -78,12 +94,6 @@ public class PizzaUserLoginWebSessionBean extends BasePizzaController implements @Any private Event loginEvent; - /** - * Template type for pages that might be displayed in guest area and login - * area. Default is guest area. - */ - private String templateType = "guest"; //NOI18N - /** * User controller */ @@ -140,6 +150,16 @@ public class PizzaUserLoginWebSessionBean extends BasePizzaController implements } } + @Override + public String getBaseTemplatePathName () { + return this.baseTemplatePathName; + } + + @Override + public void setBaseTemplatePathName (final String baseTemplatePathName) { + this.baseTemplatePathName = baseTemplatePathName; + } + @Override public String getCurrentPassword () { return this.currentPassword; @@ -160,16 +180,6 @@ public class PizzaUserLoginWebSessionBean extends BasePizzaController implements this.loggedInUser = loggedInUser; } - @Override - public String getTemplateType () { - return this.templateType; - } - - @Override - public void setTemplateType (final String templateType) { - this.templateType = templateType; - } - @Override public boolean ifCurrentPasswordMatches () { // The current password must be set and not empty -- 2.39.5