From: Roland Häder Date: Mon, 1 Aug 2016 15:57:56 +0000 (+0200) Subject: Continued a bit: (please cherry-pick) X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=a334f836ecd06179d82ca10b98a64e25fc8a1696;p=jfinancials-war.git Continued a bit: (please cherry-pick) - basicly added (unfinished) setting flag "user must change password" Signed-off-by: Roland Häder Signed-off-by: Roland Häder --- diff --git a/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionBean.java b/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionBean.java index 5caebaea..749a5d9c 100644 --- a/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionBean.java +++ b/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionBean.java @@ -268,6 +268,11 @@ public class AddressbookUserLoginWebSessionBean extends BaseAddressbookControlle return UserUtils.ifPasswordMatches(container, this.getLoggedInUser()); } + @Override + public boolean ifUserMustChangePassword () { + return (this.isUserLoggedIn() && this.getLoggedInUser().getUserMustChangePassword()); + } + @Override public boolean isInvisible () { // Check on login diff --git a/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionController.java b/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionController.java index a4b7615b..826c6a21 100644 --- a/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionController.java +++ b/src/java/org/mxchange/addressbook/beans/login/AddressbookUserLoginWebSessionController.java @@ -83,6 +83,13 @@ public interface AddressbookUserLoginWebSessionController extends Serializable { */ boolean isUserLoggedIn (); + /** + * Checks whether the user needs to change password + *

+ * @return Whether the user needs to change password + */ + boolean ifUserMustChangePassword (); + /** * Whether the currently logged-in user is invisible *

diff --git a/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestBean.java b/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestBean.java index 13ec9882..7a3a50d0 100644 --- a/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestBean.java +++ b/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestBean.java @@ -110,6 +110,11 @@ public class AddressbookAdminUserWebRequestBean extends BaseAddressbookControlle @Any private Event userLinkedEvent; + /** + * Flag whether user must change password after login + */ + private Boolean userMustChangePassword; + /** * User name */ @@ -375,6 +380,16 @@ public class AddressbookAdminUserWebRequestBean extends BaseAddressbookControlle this.userName = userName; } + @Override + public Boolean getUserMustChangePassword () { + return this.userMustChangePassword; + } + + @Override + public void setUserMustChangePassword (final Boolean userMustChangePassword) { + this.userMustChangePassword = userMustChangePassword; + } + @Override public String getUserPassword () { return this.userPassword; diff --git a/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestController.java b/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestController.java index b8ddc311..e9bace4e 100644 --- a/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestController.java +++ b/src/java/org/mxchange/addressbook/beans/user/AddressbookAdminUserWebRequestController.java @@ -91,4 +91,18 @@ public interface AddressbookAdminUserWebRequestController extends Serializable { */ void setUserPasswordRepeat (final String userPasswordRepeat); + /** + * Getter for flag if user needs to change password + *

+ * @return Flag if user needs to change password + */ + Boolean getUserMustChangePassword (); + + /** + * Setter for flag if user needs to change password + *

+ * @param userMustChangePassword Flag if user needs to change password + */ + void setUserMustChangePassword (final Boolean userMustChangePassword); + } diff --git a/src/java/org/mxchange/localization/bundle_de_DE.properties b/src/java/org/mxchange/localization/bundle_de_DE.properties index 14a4e5b3..e156691f 100644 --- a/src/java/org/mxchange/localization/bundle_de_DE.properties +++ b/src/java/org/mxchange/localization/bundle_de_DE.properties @@ -614,3 +614,4 @@ ADMIN_COUNTRY_I18N_KEY_REQUIRED=Bitte geben Sie den Schl\u00fcssel f\u00fcr das ADMIN_COUNTRY_CODE_REQUIRED=Bitte geben Sie den L\u00e4ndercode ein (z.B. DE f\u00fcr Deutschland). ADMIN_COUNTRY_ABORAD_DIAL_PREFIX_REQUIRED=Bitte geben Sie die Vorwahl f\u00fcr Auslandsgespr\u00e4che ein (z.B. + oder 00). ADMIN_MOBILE_PROVIDER_DIAL_PREFIX_REQUIRED=Bitte geben Sie die Vorwahl ohne f\u00fchrende Null f\u00fcr den Mobilfunkanbieter ein (z.B. 177 f\u00fcr E+). +USER_LOGIN_MUST_CHANGE_PASSWORD=Sie m\u00fcssen Ihr Passwort \u00e4ndern. Dies darf nicht mit dem aktuellen \u00fcbereinstimmen. diff --git a/src/java/org/mxchange/localization/bundle_en_US.properties b/src/java/org/mxchange/localization/bundle_en_US.properties index 6b2f3059..f90b02e3 100644 --- a/src/java/org/mxchange/localization/bundle_en_US.properties +++ b/src/java/org/mxchange/localization/bundle_en_US.properties @@ -543,7 +543,6 @@ ADMIN_CONTACT_FAX_NUMBER=Fax number: PAGE_TITLE_ADMIN_EXPORT_CONTACT=Export contact data CONTENT_TITLE_ADMIN_EXPORT_CONTACT=Export contact data: ADMIN_EXPORT_CONTACTS_TITLE=Start data export -#Bei sehr gro\u00dfen Datenmengen kann es eventuell zu Zeit\u00fcberschreitungen kommen. Daher sollten Sie besser seitenweise exportieren. ADMIN_EXPORT_CONTACTS_TIMEOUT_WARNING=Big data amount may lead to timeouts. You should then try to export each page separately. BUTTON_ADMIN_EXPORT_CONTACTS_CSV=Export all data as CSV file BUTTON_ADMIN_EXPORT_CONTACTS_XLS=Export all data as Excel file @@ -612,3 +611,4 @@ ADMIN_COUNTRY_I18N_KEY_REQUIRED=Please enter the key for the language package (e ADMIN_COUNTRY_CODE_REQUIRED=Please enter country code (e.g. US for U.S.A.). ADMIN_COUNTRY_ABORAD_DIAL_PREFIX_REQUIRED=Please enter dial prefix for abroad calls (e.g. + or 00). ADMIN_MOBILE_PROVIDER_DIAL_PREFIX_REQUIRED=Please enter dial prefix for mobile provider. +USER_LOGIN_MUST_CHANGE_PASSWORD=Please change your password. It must not match with your current one. 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 511af3b0..e8b209de 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,6 +52,18 @@

+
+
+ +
+ +
+ +
+ +
+
+
  • diff --git a/web/user/login_change_email_address.xhtml b/web/user/login_change_email_address.xhtml index 8e86d06f..3fb7ca98 100644 --- a/web/user/login_change_email_address.xhtml +++ b/web/user/login_change_email_address.xhtml @@ -15,46 +15,54 @@ - - -
    -
    - -
    - - -
    -
    - - - + +
    +
    + +
    -
    -
    - -
    + +
    +
    + + + -
    - -
    +
    +
    + +
    -
    +
    +
    - -
    -
    +
    +
    - - -
    + +
    +
    + + + + +
    +
    +
    + + - -
    + + + - - - + + +
    diff --git a/web/user/login_change_personal_data.xhtml b/web/user/login_change_personal_data.xhtml index 85693ac4..ee9f01fa 100644 --- a/web/user/login_change_personal_data.xhtml +++ b/web/user/login_change_personal_data.xhtml @@ -15,29 +15,31 @@ - - -
    -
    - -
    + +
    +
    + +
    - - + + - + - + - - -
    -
    + + +
    +
    + + - + + diff --git a/web/user/login_contact_data_saved.xhtml b/web/user/login_contact_data_saved.xhtml index 08609097..5be91812 100644 --- a/web/user/login_contact_data_saved.xhtml +++ b/web/user/login_contact_data_saved.xhtml @@ -15,12 +15,14 @@
    - - - - - - + + + + + + + + diff --git a/web/user/login_edit_user_data.xhtml b/web/user/login_edit_user_data.xhtml index 1bd39597..1270ebf0 100644 --- a/web/user/login_edit_user_data.xhtml +++ b/web/user/login_edit_user_data.xhtml @@ -2,10 +2,10 @@ + xmlns:ui="http://xmlns.jcp.org/jsf/facelets" + xmlns:h="http://xmlns.jcp.org/jsf/html" + xmlns:f="http://xmlns.jcp.org/jsf/core" + > #{msg.PAGE_TITLE_LOGIN_EDIT_USER_DATA} @@ -15,7 +15,7 @@ - +
    @@ -27,15 +27,23 @@
      -
    • - -
    • -
    • - -
    • -
    • - -
    • + +
    • + +
    • +
      + + +
    • + +
    • +
      + + +
    • + +
    • +
    diff --git a/web/user/login_index.xhtml b/web/user/login_index.xhtml index 59fae4fe..c9f81237 100644 --- a/web/user/login_index.xhtml +++ b/web/user/login_index.xhtml @@ -15,10 +15,14 @@ - + Here goes your content. + + + + diff --git a/web/user/login_user_data_saved.xhtml b/web/user/login_user_data_saved.xhtml index b8c7fb11..b6e46385 100644 --- a/web/user/login_user_data_saved.xhtml +++ b/web/user/login_user_data_saved.xhtml @@ -15,12 +15,16 @@ - + + + + +