From fd7f0195332816cc057ac143397e7272cd8580b3 Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Mon, 8 Aug 2016 10:46:12 +0200 Subject: [PATCH] [FIX] web: properly position invisible elements in editable listview in modals When positioning an element in an editable list view, that element is temporarily forced to display: block thanks to the class o_temp_visible The rule is written in LESS thanks to: .o_list_editable .o_temp_visible { display: block!important; } which is ok for normal invisible form fields because it is written as .o_form_view .o_form_invisible { display: none!important; } which has the same priority but is defined before the o_temp_visible rule, so the display is properly forced to block. However, for some reason, there also is the rule: .modal .modal-dialog .o_form_invisible { display: none!important; } which has a higher priority than the o_temp_visible rule. This is why appearing invisible fields in editable list view in modals are at a wrong position. The solution introduced by this commit is the safest: adding a new rule to force display block!important on the selector: .o_list_editable .o_temp_visible.o_form_invisible --- addons/web/static/src/less/list_view.less | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/addons/web/static/src/less/list_view.less b/addons/web/static/src/less/list_view.less index e335fc2ca82..7097f51eba8 100644 --- a/addons/web/static/src/less/list_view.less +++ b/addons/web/static/src/less/list_view.less @@ -79,7 +79,7 @@ // Grouped list views tbody > tr.o_group_header { .o-vertical-gradient(#fcfcfc, #dedede); - + .o_group_name { white-space: nowrap; } @@ -114,6 +114,10 @@ .o_temp_visible { opacity: 0; display: block!important; + + &.o_form_invisible { + display: block!important; + } } .o_list_view {