![]() | clearString neatComponents
|
|
![]() | clearString neatComponents
|
| |
Record Links with a cascade - an example |
![]() | ||
![]() | Techniques & KB Articles | ![]() |
Record Links with a cascade - an example |
![]() | ![]() |
This example shows how to configure a Record Link field to display as a cascade.
Download the example site, and use this documentation to understand how it was constructed before adapting it for your own needs.
Download the finished example site
- or -
Start with the earlier example site, that this demonstration starts from, and follow the documentation to replicate the example site yourself.
A cascade is a way of getting a selection from a user by first offering a broad category choice, and then on the basis of their selection, providing a second list to choose from.
If you only have a short list of items to choose from, they fit easily in a dropdown list, and there is no need to consider using a cascade.
However if the selection is long, it won't fit into a dropdown nicely, and the system will move over to using a search interface. That's fine if the user knows what they are aiming for, but sometimes you still want to allow them to browse. Cascades allow this.
If the selection is very long, it will also impact on performance, as the whole list has to be downloaded before it can be displayed. However, with a cascade only the list being displayed at each stage is downloaded, so page display is faster, and bandwidth overhead is reduced.
This example continues on from the Record Link example. Read that first to become familiar with Record Links.
In the example, we start with a Record Link that allows a US State to be selected. We will extend that to use a cascade such that the user is first asked to select a country, and then is presented with a list of States within the chosen country.
First we need to create the Table containing the Countries
The configuration should look like this:
Now we need to populate the Table with the names of the Countries. We'll just add two to get started.
From the Toolbox, choose View Table
Click the link 'Click here to submit a new record'
Enter a Country name, and Click 'Submit Form'
You are then shown a confirmation of the entry. To enter another record, choose View Table from the Toolbox.
When done, the form should show them all (or in our case, just two for now):
Now we have our list of Countries, we link to it using a Record Link field on the State Table.
Now we need to add in some more entries into the State table for Canada.
For each one, enter the name of the State / Province, and then select Canada from the Country dropdown.
Now we can configure the cascade, which will appear on the 'Contact' Table.
At the moment, when entering a new record into the 'Contact' form, a dropdown or search picker is shown.
We will change this so a dropdown is first shown asking for the Country, followed by another asking for the State
OK, out of the dialog to save changes.
Now, when you enter a new record in the 'Contact' Table, you are asked to choose a country. The State dropdown is shown too, as a hint of what will be asked next, but for now is greyed out.
Once the country is selected, the State dropdown retrieves its list from the server, and is activated to allow the use to select the state
Countries in English csv...
States and Provinces csv...
See also - Simple csv import
|