CC-4781: Store localization settings on a per-user basis

-done
This commit is contained in:
denise 2013-01-03 16:19:02 -05:00
parent a1837366be
commit e2c87ed8b6
7 changed files with 80 additions and 9 deletions

View file

@ -34,7 +34,13 @@ $front->registerPlugin(new RabbitMqPlugin());
//localization configuration
$codeset = 'UTF-8';
$lang = Application_Model_Preference::GetLocale().'.'.$codeset;
$auth = Zend_Auth::getInstance();
if ($auth->hasIdentity()) {
$id = $auth->getIdentity()->id;
$lang = Application_Model_Preference::GetCurrentUserLocale($id).'.'.$codeset;
} else {
$lang = Application_Model_Preference::GetLocale().'.'.$codeset;
}
putenv("LC_ALL=$lang");
putenv("LANG=$lang");