Joget DX Beta Available for Download
Check out Joget DX, the next generation successor to Joget Workflow for faster, simpler digital transformation.
Multirow Form Binder enables you to save multirow data (i.e., grid data) into its designated table.
In the example below, one can make use of this binder in Enhanced Grid Form Element (Form Grid) to store items for the Application Form.
Figure 1: Application Form (Table Name: applications)
In Figure 1, apart from normal input fields, there's a Form Grid element that makes reference to Item Form (as shown below).
Figure 2: Item Form (Table Name: application_items)
In Figure 2, one will need to add an additional (hidden) field as the foreign key (parent_id) to the Application Form.
Figure 3: Configuring Form Grid
As required by the Form Grid setup, one will need to match the columns with the referencing table.
Figure 4: Configuring Load and Store Binder Using Multirow Form Binder
And finally, to make sure that the grid data is saved into the application_items table, select Multirow Form Binder as both store and load binders. Then, choose Item form and map the foreign key to parent_id as required.