Allow child_of with integer also for many2many

This commit is contained in:
Cédric Krier committed 2008-05-26 11:44:23 +02:00
1 parent 6fef219728
commit 0e7f26e687
1 file changed
+2
+2
View File
@@ -2159,6 +2159,8 @@ class ORM(object):
ids2 = [x[0] for x in self.pool.get(
field._obj).name_search(cursor, user, args[i][2], [],
'like', context=context)]
elif isinstance(args[i][2], (int, long)):
ids2 = [args[i][2]]
else:
ids2 = args[i][2]