diff options
author | mark <mark> | 2011-06-29 19:36:34 +0000 |
---|---|---|
committer | mark <mark> | 2011-06-29 19:36:34 +0000 |
commit | 8c1852c540807f0f06e62984f13d71de929e9159 (patch) | |
tree | aa459e3976f5b646deb2eab889c93613c818c40f /httemplate/pref | |
parent | 2b038fbfe3d8df457208123fb46ff27575a7d872 (diff) |
sync locale settings with RT, #13073
Diffstat (limited to 'httemplate/pref')
-rw-r--r-- | httemplate/pref/pref-process.html | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/httemplate/pref/pref-process.html b/httemplate/pref/pref-process.html index 6f3518561..4ff878fd7 100644 --- a/httemplate/pref/pref-process.html +++ b/httemplate/pref/pref-process.html @@ -73,4 +73,14 @@ unless ( $error ) { # if ($access_user) { } +if ( !$error and ($FS::TicketSystem::system || '') eq 'RT_Internal' ) { + # sync RT user locale on every update + my $locale = $access_user->option('locale'); + FS::TicketSystem->init; + my $UserObj = FS::TicketSystem->session('')->{'CurrentUser'}->UserObj; + # Bypass RT ModifySelf ACL + $UserObj->CurrentUser( RT::SystemUser ); + my ($val, $msg) = $UserObj->SetLang($locale); + $error = $msg if !$val; +} </%init> |