From: Roland Häder Date: Mon, 23 May 2016 07:48:59 +0000 (+0200) Subject: set user's initial locale from given one X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=e1f61f67b9e1ecef3547eaef118aa305566675ae;p=jfinancials-war.git set user's initial locale from given one Signed-off-by: Roland Häder --- diff --git a/src/java/org/mxchange/addressbook/beans/user/AddressbookUserWebSessionBean.java b/src/java/org/mxchange/addressbook/beans/user/AddressbookUserWebSessionBean.java index 0a1a39cc..d583d847 100644 --- a/src/java/org/mxchange/addressbook/beans/user/AddressbookUserWebSessionBean.java +++ b/src/java/org/mxchange/addressbook/beans/user/AddressbookUserWebSessionBean.java @@ -35,6 +35,7 @@ import javax.naming.InitialContext; import javax.naming.NamingException; import org.mxchange.addressbook.beans.BaseAddressbookController; import org.mxchange.addressbook.beans.contact.AddressbookContactWebSessionController; +import org.mxchange.addressbook.beans.localization.AddressbookLocalizationSessionController; import org.mxchange.addressbook.beans.login.AddressbookUserLoginWebSessionController; import org.mxchange.addressbook.beans.register.AddressbookUserRegisterWebSessionController; import org.mxchange.jcontacts.contact.Contact; @@ -81,6 +82,12 @@ public class AddressbookUserWebSessionBean extends BaseAddressbookController imp @Inject private AddressbookContactWebSessionController contactController; + /** + * Localization controller + */ + @Inject + private AddressbookLocalizationSessionController localizationController; + /** * Login bean (controller) */ @@ -441,7 +448,8 @@ public class AddressbookUserWebSessionBean extends BaseAddressbookController imp this.setUserPasswordRepeat(randomPassword); } - // Set user name and mode + // Set local, user name and mode + user.setUserLocale(this.localizationController.getLocale()); user.setUserName(this.getUserName()); user.setUserProfileMode(this.getUserProfileMode());