Fix read override when ids is an int for issue1600

(transplanted from 20e6fa780d5c708c5037900339d91c42900da765)
This commit is contained in:
Cédric Krier committed 2010-06-24 20:10:32 +02:00
1 parent 85b590ec0a
commit 9df13a0349
1 file changed
+4 -4
+4 -4
View File
@@ -142,10 +142,10 @@ class View(Model):
self.dashboard_id(cursor.dbname)
if fields_names is None \
or 'arch' in fields_names:
if isinstance(ids, (int, long)) \
and dashboard_id == ids:
res['arch'] = self.dashboard_view(cursor, user, res['arch'],
context=context)
if isinstance(ids, (int, long)):
if dashboard_id == ids:
res['arch'] = self.dashboard_view(cursor, user,
res['arch'], context=context)
elif dashboard_id in ids:
for res2 in res:
if res2['id'] == dashboard_id: