Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
1 Rispondi
6076 Visualizzazioni

Hello


how to hide required fields ?
i have checkbox when it true it hide required fields then when click on save cannot save because the  required is empty 

Avatar
Abbandona
Risposta migliore

Hi MOH,

You can make a field invisible by giving invisible attribute. In the case of the the required field, you cannot save the record untill you enter data in that field.

You can try like this, make the field as required based on the value in the checkbox.

<field name='test_field' attrs="{'required':[('check_field', '=', True)]}"/>

Along with the above you can add the attribute to make the field invisible.

Thanks

Avatar
Abbandona
Post correlati Risposte Visualizzazioni Attività
2
mar 23
2718
0
nov 17
5750
2
mar 15
4710
1
mar 15
7363
3
mar 15
28832