Navrang Oza (Open ERP) has proposed merging 
lp:~openerp-dev/openobject-client-web/trunk-bug-728100-noz into 
lp:openobject-client-web.

Requested reviews:
  OpenERP SA's Web Client R&D (openerp-dev-web)
Related bugs:
  #728100 many2many selection in search view not filtering 
  https://bugs.launchpad.net/bugs/728100

For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-client-web/trunk-bug-728100-noz/+merge/52038

For selection widget, parsed INT to correct domain.
-- 
https://code.launchpad.net/~openerp-dev/openobject-client-web/trunk-bug-728100-noz/+merge/52038
Your team OpenERP R&D Team is subscribed to branch 
lp:~openerp-dev/openobject-client-web/trunk-bug-728100-noz.
=== modified file 'addons/openerp/controllers/search.py'
--- addons/openerp/controllers/search.py	2011-03-02 09:50:09 +0000
+++ addons/openerp/controllers/search.py	2011-03-03 11:01:59 +0000
@@ -319,8 +319,13 @@
                     search_data[field] = value
 
                 elif 'selection_' in value:
-                    domain.append((field, '=', value.split('selection_')[1]))
-                    search_data[field] = value.split('selection_')[1]
+                    try:
+                        val = int(value.split('selection_')[1])
+                    except:
+                        val = value.split('selection_')[1]
+                        
+                    domain.append(field, '=', val)
+                    search_data[field] = val
                 else:
                     if not 'm2o_' in value:
                         operator = 'ilike'

_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help   : https://help.launchpad.net/ListHelp

Reply via email to