Dear Cedric, Thanks for the response. On Mon, Feb 13, 2017 at 4:35 AM, Cédric Krier <[email protected]> wrote:
> 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. > You are right! But, there should be some way to place some read only attributes in the users' context which are set by Administrator and can be viewed by user. Khurram. -- 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/CAM3N3Cyn%3DQ7CtE7hkpzAzQGOPp5DVn2bw%2BnPa_Uk0FNOgR_fiQ%40mail.gmail.com.
