[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:
@@ -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
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user