⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

How to show/hide form fields when checked or unchecked a checkbox?



qataritsolutions2017
  • profile picture
  • Member

Posted 04 September 2017 - 11:29 AM

please see the form:

 

http://rashedkhan.net/gform/property_form.html

 

Here some fields get shown when checkbox is checked. How can I do this in grocery crud.


Amit Shah
  • profile picture
  • Member

Posted 04 September 2017 - 12:41 PM

Well - there -u need to be very good with Javascript either picking up elements parent TR .. or for each TR, set the ID to the fieldname or so - somehow allowing the row to be picked up programatically. If you plan to assign the ID, then u need to edit the add / edit template for whatever theme you selected. 

 

Post you have ability to control the row, u can create your own script to hook on the change of checkboxes / dropdown (whatever your need may be). The same script u can add back to the crud functionality by using set_js.

 

Hope you reach your desired solution quickly.

 

Happy GCing :)