Merge lp:~openerp-dev/openerp-web/7.0-opw-590091-acl into lp:openerp-web/7.0

Proposed by Anaël Closson (openerp)
Status: Merged
Merged at revision: 3925
Proposed branch: lp:~openerp-dev/openerp-web/7.0-opw-590091-acl
Merge into: lp:openerp-web/7.0
Diff against target: 12 lines (+1/-1)
1 file modified
addons/web/static/src/js/search.js (+1/-1)
To merge this branch: bzr merge lp:~openerp-dev/openerp-web/7.0-opw-590091-acl
Reviewer Review Type Date Requested Status
Xavier (Open ERP) (community) Needs Fixing
Review via email: mp+162740@code.launchpad.net

Description of the change

Forward port of revid:<email address hidden>

Filters not searchable functional fields from the extended search : without store or fnct_search set.

To post a comment you must log in.
Revision history for this message
Xavier (Open ERP) (xmo-deactivatedaccount) wrote :

Pretty sure there's a typo: diff says field.funct_search, but description and <email address hidden> say fnct_search.

review: Needs Fixing
Revision history for this message
Xavier (Open ERP) (xmo-deactivatedaccount) wrote :

Also `typeof field.store === 'undefined'` could probably be simpler `field.store === undefined` or `field.store === void 0`, but that's not really important.

3921. By Anaël Closson (openerp)

[FIX] typo & imp

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'addons/web/static/src/js/search.js'
2--- addons/web/static/src/js/search.js 2013-03-28 15:35:02 +0000
3+++ addons/web/static/src/js/search.js 2013-05-07 15:23:27 +0000
4@@ -1899,7 +1899,7 @@
5 this._super(parent);
6 this.fields = _(fields).chain()
7 .map(function(val, key) { return _.extend({}, val, {'name': key}); })
8- .filter(function (field) { return !field.deprecated; })
9+ .filter(function (field) { return !field.deprecated && (field.store === void 0 || field.store || field.fnct_search); })
10 .sortBy(function(field) {return field.string;})
11 .value();
12 this.attrs = {_: _, fields: this.fields, selected: null};