From 04aed774821caeb7a384e3403924a1631f3a081b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 2 Aug 2016 11:25:04 +0200 Subject: [PATCH] Continued a bit: (please cherry-pick) - that the user must change password enforced by administrator may be not wanted everywhere, so better make it as a feature that can be disabled per project - ignored some strings for i18n MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder Signed-off-by: Roland Häder --- .../login/JobsUserLoginWebSessionBean.java | 11 ++++++++++ .../admin/user/admin_form_user_data.tpl | 20 ++++++++++--------- web/WEB-INF/web.xml | 5 +++++ web/user/login_change_email_address.xhtml | 2 +- web/user/login_change_personal_data.xhtml | 2 +- web/user/login_contact_data_saved.xhtml | 2 +- web/user/login_edit_user_data.xhtml | 6 +++--- web/user/login_index.xhtml | 2 +- web/user/login_user_data_saved.xhtml | 2 +- 9 files changed, 35 insertions(+), 17 deletions(-) diff --git a/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionBean.java index 31a76019..bad61103 100644 --- a/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionBean.java @@ -51,6 +51,16 @@ import org.mxchange.jusercore.model.user.status.UserAccountStatus; @SessionScoped public class JobsUserLoginWebSessionBean extends BaseJobsController implements JobsUserLoginWebSessionController { + /** + * Path name for guest base template + */ + private static final String GUEST_BASE_TEMPLATE_NAME = "guest/guest"; //NOI18N + + /** + * Path name for logged-in user base template + */ + private static final String USER_BASE_TEMPLATE_NAME = "login/user/user"; //NOI18N + /** * Serial number */ @@ -215,6 +225,7 @@ public class JobsUserLoginWebSessionBean extends BaseJobsController implements J // Trace message // NOISY-DEBUG System.out.println(MessageFormat.format("JobsUserLoginWebSessionBean:isUserLoggedIn: this.userLoggedIn={0} - EXIT!", this.userLoggedIn)); + // Return it return this.userLoggedIn; } diff --git a/web/WEB-INF/templates/admin/user/admin_form_user_data.tpl b/web/WEB-INF/templates/admin/user/admin_form_user_data.tpl index e8b209de..ae979a96 100644 --- a/web/WEB-INF/templates/admin/user/admin_form_user_data.tpl +++ b/web/WEB-INF/templates/admin/user/admin_form_user_data.tpl @@ -52,17 +52,19 @@
-
-
- -
+ +
+
+ +
-
- -
+
+ +
-
-
+
+
+
    diff --git a/web/WEB-INF/web.xml b/web/WEB-INF/web.xml index 4f4b592f..37c28b0e 100644 --- a/web/WEB-INF/web.xml +++ b/web/WEB-INF/web.xml @@ -41,6 +41,11 @@ javax.faces.DATETIMECONVERTER_DEFAULT_TIMEZONE_IS_SYSTEM_TIMEZONE true + + Feature: Users must change password after login (with current password). Administrators can enforce this. + is_feature_user_must_change_password_enabled + true + Faces Servlet javax.faces.webapp.FacesServlet diff --git a/web/user/login_change_email_address.xhtml b/web/user/login_change_email_address.xhtml index 3fb7ca98..d42ad5a4 100644 --- a/web/user/login_change_email_address.xhtml +++ b/web/user/login_change_email_address.xhtml @@ -15,7 +15,7 @@ - +
    diff --git a/web/user/login_change_personal_data.xhtml b/web/user/login_change_personal_data.xhtml index fb3781ac..64a62680 100644 --- a/web/user/login_change_personal_data.xhtml +++ b/web/user/login_change_personal_data.xhtml @@ -15,7 +15,7 @@ - +
    diff --git a/web/user/login_contact_data_saved.xhtml b/web/user/login_contact_data_saved.xhtml index bc8b42e9..98dd25c1 100644 --- a/web/user/login_contact_data_saved.xhtml +++ b/web/user/login_contact_data_saved.xhtml @@ -15,7 +15,7 @@ - + diff --git a/web/user/login_edit_user_data.xhtml b/web/user/login_edit_user_data.xhtml index 1270ebf0..fbdda7de 100644 --- a/web/user/login_edit_user_data.xhtml +++ b/web/user/login_edit_user_data.xhtml @@ -15,7 +15,7 @@ - +
    @@ -27,13 +27,13 @@
      - +
    • - +
    • diff --git a/web/user/login_index.xhtml b/web/user/login_index.xhtml index c9f81237..b85c6661 100644 --- a/web/user/login_index.xhtml +++ b/web/user/login_index.xhtml @@ -15,7 +15,7 @@ - + Here goes your content. diff --git a/web/user/login_user_data_saved.xhtml b/web/user/login_user_data_saved.xhtml index b6e46385..f0831d0b 100644 --- a/web/user/login_user_data_saved.xhtml +++ b/web/user/login_user_data_saved.xhtml @@ -15,7 +15,7 @@ - + -- 2.39.5