Orm: model fields may be a subset of the views.

When the view asks more fields than the OM has, the result
may have less ones. Iterate through the smallest set.

bzr revid: p_christ@hol.gr-20081118143318-vvns3suey0g4e3x6
This commit is contained in:
P. Christeas
2008-11-18 16:33:18 +02:00
parent 4b84712363
commit 4e4c02351f
+1 -1
View File
@@ -852,7 +852,7 @@ class orm_template(object):
arch = node.toxml(encoding="utf-8").replace('\t', '')
fields = self.fields_get(cr, user, fields_def.keys(), context)
for field in fields_def:
for field in fields:
fields[field].update(fields_def[field])
return arch, fields