Hello, I would like to know in Odoo 14 if there is any way how to make checkbox field on view form greyed out when set to False. It means to behave in the same way like common text fields when empty.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project management
- MRP
This question has been flagged
Hi,
Please refer the code below to change the label of checkbox to grey when it is disabled.
<div>
<label for="checkbox_field" string="ssss" style="color:black;"
attrs="{'invisible': [('checkbox_field', '=', False)]}"/>
<label for="checkbox_field" string="ssss" style="color:grey;"
attrs="{'invisible': [('checkbox_field', '=', True)]}"/>
<field name="checkbox_field" nolabel="1"/>
</div>
Regards
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
Sign upRelated Posts | Replies | Views | Activity | |
---|---|---|---|---|
|
0
Jun 21
|
1693 | ||
|
1
Sep 24
|
760 | ||
|
1
May 23
|
1543 | ||
|
1
Sep 21
|
4250 | ||
|
2
Feb 16
|
5526 |