Multiple rows for a selection criteria – the Cluster way
In some scenarios we need a flexible number of selections, such that we can’t know beforehand. for example: multiple dates range, where the user may add or remove time periods. My older solution could be found here. In this text I want to show a more general way.
A possible application may look this way: Some inputs could be given once while for others we allow multiple entries:
The data service with the clustered input appears this way in the Visual Composer: The Root consists of a single item:
The order_dates node may have multiple records. this also reflects in the nodes icons.
As seen above, the data fields for each node appear in the right-hand panel.
1. Connect a Form View element to the input port of the service:
2. From the Form View connect a Grid View.
For each UI element (Form View / Grid View) the Context Node appears in the left panel. The fields and controls selected for them appear in the right one.
3. Add a Panel element to the model, so the input UI is all organized under one element.
4. Layout Board: choose to have Control Buttons for the Grid View.
5. Check the Toolbar option for the panel. Choose Bottom for its location.
6. Add a Button to the Toolbar of the Panel and add a SUBMIT action to it.
7. Back in the Design Board, configure the link to the data service to listen to *submit.
You are now ready to run the report. Since we use a recordset node for the dates selection the users are not limited in the number of entries they add.
More UI options:
- The table could show in a popup when pressing a button, if you don’t want it to appear constantly.
- We could place the Table on another tab of a Tabstrip element.