Variables available by default:
- Showing/requiring a field based on a specific value being selected in another/different field.
// Visible expression on section Requestor Info Section values('requestFor') === 'someone else' // Set this expression in the Required constraint on fields within the // Requestor Info Section. values('requestFor') === 'someone else'
The example above conditionally shows the section “Requestor Info Section” when the “requestFor” radio button is set to “someone else”. It will also then conditionally make the fields within that section (as defined in the Form Builder) required as well.
If “me” or some other value in the “requestFor” field is selected then the Requestor Info Section will be hidden and its fields will not be required.
- Showing/requiring a field only if another specific field is not empty
//set in both the expressions for Required Condition and Visible Condition in the Agent Name field values('Agency') != "" && values('Agency') != null
The example above conditionally shows and requires the question Agent Name if the field Agency is filled out.
- Showing a field only if the request is not in review mode
//On Search by Last Name field as the Visible Condition. form('review') === false
The example shows a field used for a search only if the request isn't being displayed in review.
Note that view mode and embedded mode are options in the variables list (in Form)
NOTE: The system will apply conditions automatically on change/update of any item on the screen.