CC-5555 : Implement simple caching for preferences
fixing up code so user id is never passed in manually to a preference getter.
This commit is contained in:
parent
f45708682f
commit
06323a40fd
2 changed files with 84 additions and 80 deletions
|
@ -72,8 +72,8 @@ class UserController extends Zend_Controller_Action
|
|||
// Language and timezone settings are saved on a per-user basis
|
||||
// By default, the default language, and timezone setting on
|
||||
// preferences page is what gets assigned.
|
||||
Application_Model_Preference::SetUserLocale($user->getId());
|
||||
Application_Model_Preference::SetUserTimezone($user->getId());
|
||||
Application_Model_Preference::SetUserLocale();
|
||||
Application_Model_Preference::SetUserTimezone();
|
||||
|
||||
$form->reset();
|
||||
$this->view->form = $form;
|
||||
|
@ -143,8 +143,8 @@ class UserController extends Zend_Controller_Action
|
|||
$user->setJabber($formData['cu_jabber']);
|
||||
$user->save();
|
||||
|
||||
Application_Model_Preference::SetUserLocale($user->getId(), $formData['cu_locale']);
|
||||
Application_Model_Preference::SetUserTimezone($user->getId(), $formData['cu_timezone']);
|
||||
Application_Model_Preference::SetUserLocale($formData['cu_locale']);
|
||||
Application_Model_Preference::SetUserTimezone($formData['cu_timezone']);
|
||||
|
||||
//configure localization with new locale setting
|
||||
Application_Model_Locale::configureLocalization($formData['cu_locale']);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue