Task:
Initially the attachment button is visible to everyone, but If a checkbox is tick (True).
The button should only be visible to a certain group.
I tried putting the group on the 'groups' parameter of the button and it works, but what I want to achieve is to do it dynamically (based on the checkbox's state).
Please advice, and I appreciate if you put a sample code.
Thank you so much Odoo Community.
Tämä kysymys on merkitty
1
Vastaa
4510
Näkymät
Hi,
Try with attrs,
attrs="{'invisible':[('boolean_field','=', False)]}"
Sample:
<field name="attachment" attrs="{'invisible':[('report_type','=', 'controller')]}"/>
Thanks
Nautitko keskustelusta? Älä vain lue, vaan osallistu!
Luo tili jo tänään nauttiaksesi yksinoikeusominaisuuksista ja osallistuaksesi mahtavaan yhteisöömme!
Rekisteröidy| Aiheeseen liittyviä artikkeleita | Vastaukset | Näkymät | Toimenpide | |
|---|---|---|---|---|
|
|
2
maalisk. 23
|
11492 | ||
|
Cacher le bouton "créer" d'une liste
Ratkaistu
|
|
2
maalisk. 23
|
3456 | |
|
Add class to button from function
Ratkaistu
|
|
2
toukok. 22
|
5718 | |
|
|
0
maalisk. 22
|
2354 | ||
|
|
1
toukok. 21
|
5396 |