On 2017-02-13 00:27, Cédric Krier wrote:
> On 2017-02-12 04:55, Khurram Shahzad wrote:
> > Dear All,
> > 
> > The user can change his language from User -> Preferences -> Language. How 
> > can we restrict user so that he/she can not change his language from user 
> > menu. 
> > 
> > I have tried to add a record in Administration -> User Interface -> Models 
> > -> Model Access -> Field Access for 'language' field in res_user with 
> > 'read' access. But, even then the user can log in and change his language 
> > using User -> Preference menu.
> 
> There is not check access done when user set its preferences because it
> is his preferences (and also because only administrator has write access
> on res.user). So setting access on res.user does not change anything.

But indeed I just thought you could remove the language from the
User._context_fields, this will remove it from the preference dialog.
But side effect the UI will be in default language.
Otherwise you could override the User.set_preferences and remove any
language keys in values.

But I must say that I find very strange to want to prevent user to have
the UI in his preferred language.

-- 
Cédric Krier - B2CK SPRL
Email/Jabber: [email protected]
Tel: +32 472 54 46 59
Website: http://www.b2ck.com/

-- 
You received this message because you are subscribed to the Google Groups 
"tryton" group.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tryton/20170212233552.GU83011%40tetsuo.

Reply via email to