Difference between revisions of "Conditional Lists of Values"

From SmartWiki
Jump to: navigation, search
Line 7: Line 7:
 
[[Image:Canada-Ontario-Cities.jpg|link=]]
 
[[Image:Canada-Ontario-Cities.jpg|link=]]
  
 +
To configure this functionality, for each dependent field:
 +
* define the field that will condition the dependent values as the "Parent Field"
 +
* surround the dependent values with the ssOption syntax:
 +
 +
:<font size="3">&lt;ssOption: ''Parent Value 1''>''Dependent Value 1'';''Dependent Value 2''&lt;/ssOption></font>
  
 
[[Image:Conditional Lists - Combined.jpg|link=]]
 
[[Image:Conditional Lists - Combined.jpg|link=]]

Revision as of 12:08, 2 May 2014

The list of values selectable in a custom field can be made conditional upon the value selected in another custom field. This functionality can be configured on the following custom field types:

Canada-Ontario-Cities.jpg

To configure this functionality, for each dependent field:

  • define the field that will condition the dependent values as the "Parent Field"
  • surround the dependent values with the ssOption syntax:
<ssOption: Parent Value 1>Dependent Value 1;Dependent Value 2</ssOption>

Conditional Lists - Combined.jpg - new option "Parent Field" added for custom field types of combo boxes, radio buttons, and check boxes - "Parent Field" is to indicate if the options of the combo box/check box field are dependent to the value of another field - once selected, you can put <ssOption> syntax to indicate what options to show based on what values eg. --Select One--<ssOption:Canada>;Ontario;British Columbia</ssOption>

- this means, "--Select One--" will always show
- "Ontario" and "British Columbia" will only show if the parent field is "Canada"

another eg: -- N/A --<ssOption:Ontario>;Toronto;Ottawa</ssOption><ssOption:British Columbia>;Vancouver</ssOption>

- "-- N/A --" always show
- "Toronto" and "Ottawa" will show if the parent field is "Ontario"
- "Vancouver" will show if the parent field is "British Columbia"

This supports up to n levels and it does NOT support dynamic control fields