summaryrefslogtreecommitdiff
path: root/addons/mail/static/src/models/thread_cache/thread_cache.js
diff options
context:
space:
mode:
authorMathieu Duckerts-Antoine <dam@odoo.com>2020-05-22 19:59:48 +0000
committerJulien Mougenot <jum@odoo.com>2020-06-12 13:34:04 +0000
commit46306b95d8c3d493088170c277a9574abff8ac27 (patch)
treef888ba9888833dac39a148aff7b54c9b70f3367e /addons/mail/static/src/models/thread_cache/thread_cache.js
parent3306a0f41492ee51e93ce9cedcd42296e09df6a0 (diff)
[IMP] web: expand domain != count domain
In the search panel, the domain used to compute the field image values (when the attribute expand is false) was the same as the domain used to compute counters (if enabled). The idea was that a value bringing an empty domain is totally useless and should not displayed. That being true, it turns out that if one does not allow them and several fields are used, selecting a value in the search panel will very often totally transform the search panel. From a UI perspective, this turns out to be bad: the search panel 'moves'. Let us give an example: Let us start from a search panel that looks like to: first_field A 1 B 3 second_field C 1 D 2 <--- mouse above D E 1 with first_field and second_field both with expand="0" and enable_counters="1". Let us also assume that no record in the global domain has both first_field=A and second_field=D. Click on D would make the search panel look like to something like first_field B 1 second_field C 1 D 2 E 1 <--- mouse here (the selection of D does not impact the values for the second_field but does for the other first_field values). This has led us to use basically only the domain comming from outside of the search panel to compute field image values. This means that we might now have value with zero count even if expand is false. In the above situation, a click on D would give us first_field A B 1 second_field C 1 D 2 <--- mouse still above D E 1 Task ID: 2154749 Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com> Co-authored-by: Julien Mougenot <jum@odoo.com>
Diffstat (limited to 'addons/mail/static/src/models/thread_cache/thread_cache.js')
0 files changed, 0 insertions, 0 deletions