- 06 Sep 2023
- 4 Minutes to read
Entity Action Visibility Rules
- Updated on 06 Sep 2023
- 4 Minutes to read
Entity Actions enable users to execute various tasks. However, in specific scenarios, the ability to hide certain entity actions can enhance user experience, security, and workflow efficiency. Action Visibility Rules allow users to selectively filter and hide custom or default actions associated with specific Data Types. Configuration Folders are where developers configure these Action Visibility Rules. These Rules influence what is visible in the action menu when selecting a specific entity, ensuring that users see only relevant and permitted actions.
|Example Use Cases||Description|
|Role-Based Access Control||Depending on a user's role or permission level, you may want to hide certain actions that they shouldn't have access to. For example, only administrators should be able to delete critical data.|
|Simplifying the Interface||To reduce clutter and make the user interface more user-friendly, hide rarely used actions or only relevant to a subset of users. This ensures that users see only what's most important to them.|
|Progressive Disclosure||Hide actions in complex workflows until certain conditions or prerequisites are met. For example, you might hide the "Submit for Approval" action until a Form is fully filled out.|
Levels of Filtering
Action Visibility Rules offer two primary types of filtering:
|Level||Description||Example Use Case|
|Global Filtering||Global filtering applies rules consistently across all instances of a data type, ensuring uniform action visibility rules for all objects of the same type.||Globally filter actions that allow data deletion to ensure that only authorized users can perform such critical operations.|
|Locally Filtering||Locally filtering via Report Viewer Control allows developers to apply Action Visibility Rules at the individual Report level, offering granular control over actions for each Report.||Use local filtering to customize the actions available for each client's report. For instance, allow one client to export their data while restricting this action for others.|
Filtering by Categories vs. Action Names
When configuring Action Visibility Rules, it's essential to understand the distinction between filtering by action categories and filtering by action names:
|Filtering by Action Categories||This approach allows developers to filter out actions based on the categories the actions are in, such as 'Administrative Tasks,' 'Editing,' 'Data Management,' etc.|
Filtering by Action Names
|Filter actions individually based on the specific names for more precise control. This method is useful when needing to apply unique Rules to distinct actions regardless of the category.|
In a Designer Project, follow these steps to create and configure an Action Visibility Rule for an Entity Configuration Folder:
- Right-click on the desired Entity Configuration Folder.
- Select the Action Visibility Rule action.
- Provide a name for the Rule and click "CREATE.
- Within the Rule Designer, configure the Rule to state "if Action.Name Equals Create Insurance Claim".
- Click Add and select Add Condition. Configure the statement to read "Flow Data.InitiatingAccount.EmailAddress Contains +local".
- Click Save.
|When logged in with an account that does not contain "+local" in the email address, the Create Insurance Claim action is available to use.||After logging in with an Account containing "+local", the Create Insurance Claim Action is no longer available.|
In the Page Designer, follow these steps to create and configure an Action Visibility Rule at the Report level. A Report with the Account Data Source is being used for this example.
- Add a Report Viewer Control to the Page Designer and select the Report Source.
- In the Report Viewer Control Properties panel, expand Behavior > Actions > Filter Actions.
- There are two options available, By Category and By Name. Once one or both options are selected, a text box appears, allowing developers to type the name of the Category or Action to display in the action menu.
These are case-sensitive settings; ensure spelling and capitalization are correct. Every action that is NOT specified here will be hidden at runtime.
- Open Page that houses the configured Report.
- Select an Entity to confirm the previously specified actions are the only ones visible.
If you encounter any issues when setting up Action Visibility Rules, refer to the following troubleshooting tips:
|Actions do not behave as expected, or some remain hidden even when they shouldn't.||Review the conditions and statements within the Action Visibility Rules. Ensure that there are no conflicting rules that may unintentionally hide or reveal actions. Check for typos or errors in the rule configurations.|
|Actions are not visible to users who should have access to them based on their roles or permissions.||Double-check the user roles and permissions settings. Verify that users are assigned the correct roles and that those roles have the necessary permissions to view the actions.|
|The Action Visibility Rule doesn't seem to trigger or take effect.||Ensure that the Rule's conditions are being met. Test the Rule with different scenarios to confirm that it activates when expected. If using complex conditions, verify that all conditions are met simultaneously for the rule to trigger.|
|Actions may be hidden or revealed inconsistently due to conflicting rules.||Prioritize Rules based on their importance and use logical operators (AND, OR) to manage conflicts. Make sure that rules are designed to complement each other rather than contradict.|
|Implementing numerous or overly complex Action Visibility Rules may lead to performance issues.||Review the Rules and consider consolidating or simplifying them where possible. Excessive or highly intricate rules can impact system performance negatively. The Global Debugger can assist in pinpointing issues related to Action Visibility Rules. It provides insights into how they interact with other Designer Elements and helps identify potential problems.|
|All actions are not visible.||This typically indicates that an Action Visibility Rule was created but left blank. When a Rule lacks specific conditions and actions, it can unintentionally hide all actions associated with the object. To resolve this problem, ensure that the Action Visibility Rules are correctly configured with relevant conditions and actions to control the visibility of specific actions as intended.|
To optimize the use of Action Visibility Rules, consider these best practices:
- Organize Configuration Folders logically.
- Use clear and descriptive Rule names.
- Regularly review and update rules as application requirements evolve.