Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
5049 Переглядів

Hello, I'm using Odoo 13.


I have a form view with some fields I want to hide based on a condition:


Because showing codes does not work at the moment:

https://www.codepile.net/pile/zvDQYYoJ


"custom_field1" is a Many2one field, all the other fields are Float fields.



All fields have to be in one row and I have to use div.



So the invisible contitions works perfekt, but they left huge blank spaces, where the invisible fields are. For example, if I choose the id "(%(custom_model.custom_id_6)d)" on the field "custom_field1", the fields "custom_field3", "custom_field4", "custom_field5" get invisible, but the space is still used from them.

I thougth if I use the invisible attributes, the field gets "replaced" but thats not the case.



I already thought I could add the attribute "style="display: none;" to the fields based on the condition, but I dont know how to trigger that in a form view.

Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
0
черв. 21
14
Add Label up of form Вирішено
1
груд. 19
9222
2
квіт. 17
3349
1
бер. 15
9512
3
січ. 24
9955