diff options
| author | Xavier Morel <xmo@openerp.com> | 2014-07-10 13:43:45 +0200 |
|---|---|---|
| committer | Xavier Morel <xmo@openerp.com> | 2014-07-11 13:54:01 +0200 |
| commit | 785018cc9c6429eb79b09ae84c9c28c9da24f85a (patch) | |
| tree | d3ec419b2a1d00a07f7cacdf5311bdacfc312d70 /addons/analytic_user_function/analytic_user_function.py | |
| parent | d5eda984c9d3b858623b2002ae2a1ddcf78924a5 (diff) | |
[FIX] only prefetch other cached records with read field uncached during _read_from_database
If expansion of the recordset is done during _prefetch_field, if one of the
prefetches (not the base record(s) but one of those selected by
BaseModel._in_cache_without) can't be read by the current user (due to an
access rule or for field reading reasons, or whatever) the whole read is
failed, even if the record which was specifically asked for could be read on
its own.
By only expanding the read set in _read_from_database, the cache is correctly
set but read() and _prefetch_field() only check the records explicitly asked
for for AccessDenied, prefetched records will only be asked if they are ever
accessed.
fixes #1013
Diffstat (limited to 'addons/analytic_user_function/analytic_user_function.py')
0 files changed, 0 insertions, 0 deletions
