With conditional logic in WizyVision applications, administrators can ensure that field workers only fill in the relevant fields for their submissions. By displaying specific fields based on the value of other fields, you can streamline the data entry process and create a more efficient workflow. In this article, we'll explore how to use conditional logic to conditionally display fields in your applications.
Create an Application and conditionally display fields
To implement conditional logic in your applications, you need to understand two key elements: the source field and the target field(s).
Source Field - the value of this field will be the basis of other fields if they will be displayed or not
Target Field - these are the fields that will be displayed conditionally based on the value of the source field
Steps to add rules to conditionally display fields
On the process’s fields tab, select the field that will determine which other fields are displayed based on its value (this is your source field)
Click “edit” field
In the field settings modal, select the logic tab then select add logic
In your rule’s condition (starts with When) define the value of the source field that determines when the target field should be shown
To set up your rule’s action (beginning with Then), select the fields you want to display when the condition is met. These are considered targets for your rule.
Click Add at the bottom-right of the “add rule” dialog
Example: Office Inventory Form
Let's say you are creating an office inventory form in WizyVision.
You have a "Category" field that allows users to select the category of the asset. Based on the selected category, you want to display specific fields related to that category. For example, if the category is "Mobile Phone," additional fields such as "IMEI Number" and "Operating System" should be displayed. However, if the category is "Furniture," different fields like "Material" and "Dimensions" should be shown
Identifying "logics" in App-Builder
Target fields in a process are indicated by logic icons next to the field name.
Hovering over the icon will show the conditions that apply to that field
Behavior of conditional logic
Understanding the behavior of conditional logic is essential for effectively using this feature:
- Multiple Rules: You can add multiple conditional rules to a source field.
- Field Display: Target fields will not be displayed by default and will only appear when at least one of the source conditions is met.
- Data Submission: Target fields will only submit data if they are displayed when the case form is submitted.
- Required Fields: Required target fields are only mandatory if they are displayed when the case form is submitted.
- Field Removal: If you remove a field from the case form, any associated logic may also be removed.
- Rule Priority: When multiple logic rules affect a target field, it will be shown when any of the rules are satisfied.
Conditional logic is a powerful tool that allows you to streamline field display in WizyVision applications. By showing or hiding fields based on specific conditions, you can simplify the data entry process and ensure that users only fill in the relevant information for their submissions. In this article, we covered the steps to create conditional display rules, the behavior of conditional logic, and provided an example of how it can be used in an office inventory form.
By leveraging conditional logic in WizyVision applications, you can enhance the user experience, improve data accuracy, and create more efficient workflows. Experiment with different conditions and field combinations to tailor your applications to your specific business needs.
If you have further questions or need additional assistance, feel free to explore our related articles or reach out to our support team. We're here to help you make the most of WizyVision's powerful customization features.