diff options
| author | Géry Debongnie <ged@odoo.com> | 2019-01-31 15:38:52 +0000 |
|---|---|---|
| committer | Géry Debongnie <ged@odoo.com> | 2019-02-04 08:22:34 +0000 |
| commit | 1f5807f1c8a263cf3d5dd8c2dc02dc8219f486d2 (patch) | |
| tree | f62f043946ba52d27a7e0dc12917bd3abf8cd600 /addons/web/static/src/js/views | |
| parent | dc4e2b92aabe9f80de0ffba79901530b6a3e149e (diff) | |
[FIX] web: allow user to move cursor in search bar
With the control panel refactoring, the auto_complete widget was set on
a different target, which caused issues with the search bar: the event
handlers for the search bar were triggered before the handlers for the
auto_complete widget.
With this commit, we make sure they are handled in the proper order.
Also, a small piece of code that was supposed to check the position of
the cursor was lost.
closes odoo/odoo#30795
Diffstat (limited to 'addons/web/static/src/js/views')
| -rw-r--r-- | addons/web/static/src/js/views/control_panel/search/search_bar.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/addons/web/static/src/js/views/control_panel/search/search_bar.js b/addons/web/static/src/js/views/control_panel/search/search_bar.js index 7f0feda4516..77d6d7fa5e9 100644 --- a/addons/web/static/src/js/views/control_panel/search/search_bar.js +++ b/addons/web/static/src/js/views/control_panel/search/search_bar.js @@ -142,6 +142,7 @@ var SearchBar = Widget.extend({ var self = this; this._setupAutoCompletionWidgets(); this.autoComplete = new AutoComplete(this, { + $input: this.$('input'), source: this._getAutoCompleteSources.bind(this), select: this._onAutoCompleteSelected.bind(this), get_search_string: function () { |
