diff options
| author | Paul Morelle <pmo@odoo.com> | 2020-11-18 12:13:35 +0000 |
|---|---|---|
| committer | Paul Morelle <pmo@odoo.com> | 2020-11-18 15:30:28 +0000 |
| commit | addd392a1b5f7e569c65a4503152ba0bdfe49eb3 (patch) | |
| tree | 446e85c76509d207e2b2aa2a029b297ffb30507d /addons/mail/static/src/components/autocomplete_input | |
| parent | f22c34e7f61f7f8ac5b9ab7f9579cc4e6dd0e334 (diff) | |
[FIX] mail: select first contact in new message box
In previous versions of Odoo, in the New message box, typing a few
letters of the name of your recipient and pressing Enter would
automatically select the conversation with this contact.
Since 14.0, one has to select the first result with the Down key.
This commit restores the previous behavior by using the
[`autofocus`](https://api.jqueryui.com/autocomplete/#option-autoFocus)
option.
closes odoo/odoo#61886
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Diffstat (limited to 'addons/mail/static/src/components/autocomplete_input')
| -rw-r--r-- | addons/mail/static/src/components/autocomplete_input/autocomplete_input.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/addons/mail/static/src/components/autocomplete_input/autocomplete_input.js b/addons/mail/static/src/components/autocomplete_input/autocomplete_input.js index e9bb5286ee2..c80bbafc4c7 100644 --- a/addons/mail/static/src/components/autocomplete_input/autocomplete_input.js +++ b/addons/mail/static/src/components/autocomplete_input/autocomplete_input.js @@ -11,6 +11,7 @@ class AutocompleteInput extends Component { } let args = { + autoFocus: true, select: (ev, ui) => this._onAutocompleteSelect(ev, ui), source: (req, res) => this._onAutocompleteSource(req, res), focus: ev => this._onAutocompleteFocus(ev), |
