Esri / geoform-template-js

GeoForm is a configurable template for form based data editing of a Feature Service.
http://esri.github.io/geoform-template-js/
Apache License 2.0
67 stars 83 forks source link

Config additions: "Cascade" & "Mandatory" #463

Closed trepagnier closed 9 years ago

trepagnier commented 9 years ago

I added a couple of features to the form that can be modified in the "fields" object within the default config:

cascade

"cascade" controls the visibility of fields in the form. Any questions that follow a true/false radio field can be hidden using the following arguments:

"mandatory": true will make the field mandatory if it is visible. If it is hidden by the cascade, then the 'mandatory' class will be removed.

driskull commented 9 years ago

hey @darinacosta I think we're going to have to do something different at a later time to handle a larger use case where there's more of a decision tree. Thanks for the commit though!