Passing data between jigs
Often, you need to transfer or pass data between s to provide context and data, for example, when pressing on a customer in a list, the customer ID is passed to the order form, prepopulating the customer's details. This is accomplished by utilizing inputs and outputs.
![Parameters and Inputs Parameters and Inputs](https://archbee-image-uploads.s3.amazonaws.com/x7vdIDH6-ScTprfmi2XXX/RL4_7nNmoG_AdeM_eEaUh_jig-inputs.gif)
- The parameter and input work in conjunction with each other.
- Multiple parameters can be passed through at once.
- The receiving configuration uses the format [email protected]. Use IntelliSense (ctrl+space) to assist with configuration.
- In a , you can access all data sent from other s using the expression @ctx.jig.inputs.[parameter], for example, [email protected][customerId = @ctx.jig.inputs.customerId]
- If you in a list-item component you don't need to list all the parameters, simply use: parameters: customer: [email protected]
Parameter: In the containing the data you want to transfer, configure the various parameters to be passed. Example:
parameters: packageDate: [email protected] packageName: [email protected]
Input: In the receiving configure the input for the data in the field or data property. Example: title: [email protected]
![Output and inputs Output and inputs](https://archbee-image-uploads.s3.amazonaws.com/x7vdIDH6-ScTprfmi2XXX/a02HRAizeiq2PTPJL8pWb_jig-output.gif)
Outputs are configured in a and are then used as an input in a composite to pass data between the s in the composite . This confiugration is suitable for creating master detail screens, clicking on a component in one jig, populates the components and data in the next screen. Passing data values between s works both ways.
- The receiving configuration uses the format similar to [email protected]. Use IntelliSense (ctrl+space) to assist with configuration.
The output and input work in conjunction with each other.
outputs: output-key: [email protected]
Input: In the receiving jig.composite configure the input for the data. Example: inputs: id: [email protected]
![Doc contributor](https://s3.amazonaws.com/archbee-animals/rabbit.png)