[FIX] orm: SUPERUSER is not restricted by groups on fields

bzr revid: chs@openerp.com-20130116164025-qns65cb78p8p57m1
This commit is contained in:
Christophe Simonis 2013-01-16 17:40:25 +01:00
parent a186503285
commit c10d28e4e6
1 changed files with 1 additions and 1 deletions

View File

@ -3555,7 +3555,7 @@ class BaseModel(object):
if field_name not in self._all_columns:
return True
field = self._all_columns[field_name].column
if field.groups:
if user != SUPERUSER_ID and field.groups:
return self.user_has_groups(cr, user, groups=field.groups, context=context)
else:
return True