projects
/
odoo
/
odoo.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d801f21
)
[FIX] two loops one loop (a previous commit) was wrongly done :(.
author
Vo Minh Thu
<vmt@openerp.com>
Wed, 5 Oct 2011 13:55:49 +0000
(15:55 +0200)
committer
Vo Minh Thu
<vmt@openerp.com>
Wed, 5 Oct 2011 13:55:49 +0000
(15:55 +0200)
bzr revid: vmt@openerp.com-
20111005135549
-xvhtt57fl1ib7o6e
openerp/osv/fields.py
patch
|
blob
|
history
diff --git
a/openerp/osv/fields.py
b/openerp/osv/fields.py
index
aae6e4a
..
6cc5255
100644
(file)
--- a/
openerp/osv/fields.py
+++ b/
openerp/osv/fields.py
@@
-165,11
+165,10
@@
class reference(_column):
result = {}
# copy initial values fetched previously.
for value in values:
+ result[value['id']] = value[name]
if value[name]:
model, res_id = value[name].split(',')
- if obj.pool.get(model).exists(cr, uid, [int(res_id)], context=context):
- result[value['id']] = value[name]
- else:
+ if not obj.pool.get(model).exists(cr, uid, [int(res_id)], context=context):
result[value['id']] = False
return result