Mohammed Shekha(Open ERP) has proposed merging 
lp:~openerp-dev/openerp-web/6.1-opw-574881-msh into lp:openerp-web/6.1.

Requested reviews:
  OpenERP Core Team (openerp)

For more details, see:
https://code.launchpad.net/~openerp-dev/openerp-web/6.1-opw-574881-msh/+merge/106739

Hello,

Fixed the issue of advance filter, removed the fields which are not searchable 
or on which fnct_search is false or store is false, here from xml we have 
removed it but in js when it goes to call select_field at that time these 
fields will be available in this.fields.


This will cause issue like as follow.

Go to Product list view -> Select Advance Filter -> the active field is boolean 
so in select_field there will be two option "is true" and "is false", now same 
thing do in dutch language, you will get active as a first field but select 
field will have operators of float, because we have filtered fields which are 
not searchable in xml but whicle goinf to create select_field(Operator 
selection) at that time these fields are there hence label will be "Active" but 
it will create operator selection as float as _product_available is float field.

Thanks.
-- 
https://code.launchpad.net/~openerp-dev/openerp-web/6.1-opw-574881-msh/+merge/106739
Your team OpenERP R&D Team is subscribed to branch 
lp:~openerp-dev/openerp-web/6.1-opw-574881-msh.
=== modified file 'addons/web/static/src/js/search.js'
--- addons/web/static/src/js/search.js	2012-05-18 09:44:43 +0000
+++ addons/web/static/src/js/search.js	2012-05-22 04:34:20 +0000
@@ -1220,7 +1220,13 @@
      */
     init: function (parent, fields) {
         this._super(parent);
-        this.fields = _(fields).chain()
+        filtered_fields = {}
+        _.each(fields, function(field, name){
+            if(typeof field.store === 'undefined' || field.store || field.fnct_search){
+                filtered_fields[name] = field
+            }
+        });
+        this.fields = _(filtered_fields).chain()
             .map(function(val, key) { return _.extend({}, val, {'name': key}); })
             .sortBy(function(field) {return field.string;})
             .value();

_______________________________________________
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