[FIX] orm: revert change - do not write on related fields upon record creation

bzr revid: rco@openerp.com-20120402125629-ozk2nvdue9p4wiqo
This commit is contained in:
Raphael Collet 2012-04-02 14:56:29 +02:00
parent c2c44a28f9
commit f54f2c5509
1 changed files with 2 additions and 1 deletions

View File

@ -4165,7 +4165,8 @@ class BaseModel(object):
upd1 = upd1 + ',' + self._columns[field]._symbol_set[0]
upd2.append(self._columns[field]._symbol_set[1](vals[field]))
else:
upd_todo.append(field)
if not isinstance(self._columns[field], fields.related):
upd_todo.append(field)
if field in self._columns \
and hasattr(self._columns[field], 'selection') \
and vals[field]: