[FIX] res.users: safer read() when computing default company value
authorOlivier Dony <odo@openerp.com>
Fri, 25 Jul 2014 14:33:48 +0000 (16:33 +0200)
committerOlivier Dony <odo@openerp.com>
Fri, 25 Jul 2014 14:33:48 +0000 (16:33 +0200)
commitf90b29b9382b8865a055f72432a85b2837642d7c
tree31ed0776b7ce9956b6d3cdd5e83e49b13a0f9dbd
parent48140f113a38fc77fdaad509f65b01fd2d1f7aa8
[FIX] res.users: safer read() when computing default company value

The goal is to avoid any kind of prefetching
of other fields when copmuting the default
company, as this will sometimes happen in the
middle of a database update, when the default
company is used for setting the default value
of new columns. In that case the db schema
may not fully match the in-memory model, leading
to an SQL error.
openerp/addons/base/res/res_users.py