summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js
diff options
context:
space:
mode:
authorMathieu Duckerts-Antoine <dam@odoo.com>2021-02-10 15:17:33 +0000
committerMathieu Duckerts-Antoine <dam@odoo.com>2021-02-12 09:22:50 +0000
commitad5d642c455d3215857f25e0d69c593324178d29 (patch)
treea8f1c0a15c2686d8bf1cede5f7e21f036170809f /addons/web/static/src/js
parent850581c49c84042bd5b40b632798c56789a1c60e (diff)
[FIX] web: boolean field autocompletion with 'No'
Before this commit, select the "No" option of a boolean field in the search bar autocompletion menu would crash. closes odoo/odoo#65896 Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Diffstat (limited to 'addons/web/static/src/js')
-rw-r--r--addons/web/static/src/js/control_panel/search_bar.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/web/static/src/js/control_panel/search_bar.js b/addons/web/static/src/js/control_panel/search_bar.js
index 0dc8599c4ab..c3f8d1ec4d6 100644
--- a/addons/web/static/src/js/control_panel/search_bar.js
+++ b/addons/web/static/src/js/control_panel/search_bar.js
@@ -278,7 +278,7 @@ odoo.define('web.SearchBar', function (require) {
const labelValue = source.label || this.state.inputValue;
this.model.dispatch('addAutoCompletionValues', {
filterId: source.filterId,
- value: source.value || this._parseWithSource(labelValue, source),
+ value: "value" in source ? source.value : this._parseWithSource(labelValue, source),
label: labelValue,
operator: source.filterOperator || source.operator,
});