summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/views/list
diff options
context:
space:
mode:
authorMohammed Shekha <msh@odoo.com>2020-12-21 08:54:35 +0000
committerMohammed Shekha <msh@odoo.com>2021-01-05 11:26:42 +0000
commit2ddb8e07ab9fcce3427266247069de8546a87fb5 (patch)
treea95b9d65d410c2f405df37b58b0b66c4217119d2 /addons/web/static/src/js/views/list
parenta14c74d926b35dc499914edcbb7b93e638fe3bce (diff)
[FIX] web: list: keep line when click in m2o dropdown
Before this commit, in editable list views with a many2one, when the user clicked inside the many2one dropdown, in the padding above the first item or below the last item, the dropdown closed itself and the row was removed (if it wasn't dirty yet). This commit fixes that issue by ignoring clicks at those specific spots. Task 2377864 closes odoo/odoo#63993 X-original-commit: dd40745dfdc98e82142e64ca58c0c976f6ad8d97 Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Diffstat (limited to 'addons/web/static/src/js/views/list')
-rw-r--r--addons/web/static/src/js/views/list/list_editable_renderer.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/web/static/src/js/views/list/list_editable_renderer.js b/addons/web/static/src/js/views/list/list_editable_renderer.js
index 2cfe3191a99..2122e00ed0c 100644
--- a/addons/web/static/src/js/views/list/list_editable_renderer.js
+++ b/addons/web/static/src/js/views/list/list_editable_renderer.js
@@ -1811,7 +1811,7 @@ ListRenderer.include({
}
// ignore clicks in autocomplete dropdowns
- if ($(event.target).parents('.ui-autocomplete').length) {
+ if ($(event.target).closest('.ui-autocomplete').length) {
return;
}