[FIX] models: recompute fields with user admin to prevent access rights issues

This commit is contained in:
Raphael Collet 2015-01-22 13:48:09 +01:00
parent e9d1d7aac0
commit 8cd2cc8910
1 changed files with 2 additions and 1 deletions

View File

@ -845,7 +845,8 @@ class Environment(object):
def add_todo(self, field, records):
""" Mark `field` to be recomputed on `records`. """
recs_list = self.all.todo.setdefault(field, [])
recs_list.append(records)
# use user admin for accessing records without access rights issues
recs_list.append(records.sudo())
def remove_todo(self, field, records):
""" Mark `field` as recomputed on `records`. """