[FIX] web: autocomplete selection not hidden
Appending the autocomplete selection too close from the input field leads to display (hidden) problem in some cases (Many2one inside modals views, many2one at the end of a form view, etc.)
This is related to rev. e1cde4d038
closes #4268
This commit is contained in:
parent
9dad29caaf
commit
4a3e5df93a
|
@ -3736,7 +3736,10 @@ instance.web.form.FieldMany2One = instance.web.form.AbstractField.extend(instanc
|
|||
minLength: 0,
|
||||
delay: 250,
|
||||
});
|
||||
var appendTo = this.$el.parent().parent();
|
||||
var appendTo = this.$el.parents('.oe_view_manager_body, .modal-dialog').last();
|
||||
if (appendTo.length === 0){
|
||||
appendTo = '.oe_application > *';
|
||||
}
|
||||
this.$input.autocomplete({
|
||||
appendTo: appendTo
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue