summaryrefslogtreecommitdiff
path: root/addons/analytic_user_function
diff options
context:
space:
mode:
authorOlivier Dony <odo@openerp.com>2015-03-18 11:22:39 +0100
committerOlivier Dony <odo@openerp.com>2015-03-18 11:40:51 +0100
commit489a96c2572bbe2cc04c0658ed2b862aca31fc0f (patch)
treec3912b31e4e5901ea08666f3f96474626531f4cd /addons/analytic_user_function
parent6aa28a89bb31389cbdef8b447475d0ecc2dd122d (diff)
[FIX] product.template: name_search order + mismatch on IDs
Improve commit bf31ab6718a8b9c8afdd29120e5056533b0a2ade: - do not use the product.product name_search() when there is no search term (it's only useful with a search term - do not use the product.product name_search() when the extra domain (args) has a criterion on IDs - these will be *template* ids, not *variant* ids, so the results would be wrong - Since templates and variants use a different natural `_order`, perform an extra name_search() on templates after gathering the ids to return, to apply the proper sort ordering. Increases the penalty by doing 2 name_search() calls. This issue could be seen e.g. in the breadcrumbs where the display_name variable is displayed for templates, and indirectly relies on name_search() due to an old hack in call_kw in order to implement the "future_display_name".
Diffstat (limited to 'addons/analytic_user_function')
0 files changed, 0 insertions, 0 deletions