summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOlivier Dony <odo@openerp.com>2011-02-01 22:01:40 +0100
committerOlivier Dony <odo@openerp.com>2011-02-01 22:01:40 +0100
commitd4c473f502847c976dd9125ad2d698caa6cd29d5 (patch)
treef064128dd1b9b9a3154ff9eed87e8368fa618111
parentde6c15049e7474acee48128260cec138612dcf37 (diff)
[REVERT] fields: revert previous fix, until tests and addons are checked for compatibility
bzr revid: odo@openerp.com-20110201210140-gmr25730fiuvq7e5
-rw-r--r--bin/osv/fields.py14
1 files changed, 0 insertions, 14 deletions
diff --git a/bin/osv/fields.py b/bin/osv/fields.py
index b7874cda8e6..72df0e925ad 100644
--- a/bin/osv/fields.py
+++ b/bin/osv/fields.py
@@ -339,20 +339,6 @@ class many2one(_column):
result = {}
for id in ids:
result[id] = obj.datas[id].get(name, False)
-
- # build a dictionary of the form {'id_of_distant_resource': name_of_distant_resource}
- # we use uid=1 because the visibility of a many2one field value (just id and name)
- # must be the access right of the parent form and not the linked object itself.
- obj = obj.pool.get(self._obj)
- records = dict(obj.name_get(cr, 1,
- list(set([x for x in result.values() if x and isinstance(x, (int,long))])),
- context=context))
- for id in ids:
- if result[id] in records:
- result[id] = (result[id], records[result[id]])
- else:
- result[id] = False
-
return result
def get(self, cr, obj, ids, name, user=None, context=None, values=None):