Restrict Entity Actions By RulesLast Updated: 07/15/2016 Introduced in Verision: 2.0
Action Visibility Rule feature was implemented in Decisions 3.2.0. This feature allows administrators to remove any Entity actions using Rules. In order to accomplish this, Portal administrator creates Entity Actions And Configuration sub folder where he or she is able to create Action Visibility Rules.
In this example we are going to remove Delete Document action for the Document type entities using Action Visibility Rule.
We begin in the Designer Folder where we have a Document entity added for this example. At this point if we right click on this Document entity and select Manage category, we can see that Delete Document action is present and visible.
On the Folder Actions Panel we select Datatypes/Database > Configuration Extension > Add Entity Actions And Configuration.
In the resulting pop-up window we search for Document Type Name, add it and click Ok to save and close this pop-up window.
With previous step we created Document Configuration Extension Designer Sub Folder. Next, we navigate to this sub folder.
Then, we click Action Visibility Rule button on the Document Configuration Extension Folder Actions Panel.
Next, we Name our Rule and click Create to proceed to the Rule Designer.
Mention, this type of Rules do not allow user to add any Input Data. Moreover, they have specific Input Data like Entity and Action that is extremely useful. We click Add New Rule Step to start building our Rule.
First, we expand Action [ActionHeader] category and pick Category [String]. Then, we click Next.
In the Verb definition window we select Is and click Next to proceed.
In the resulting window we leave Mapping Type Constant and define Value as Manage because our Delete Document action is under Manage category. Click Done to save this Rule Phrase.
In the resulting window we click Add New Rule Step.
This time we pick ActionUniqueName [String] from Action [ActionHeader] category and click Next.
In the Verb definition window we select Contains from Text Rules category and click Next.
In the resulting window we leave Case Insensitive CheckBox checked, and for the value we set Mapping Type Constant with Value “delete”. Click Done to save the Rule Phrase.
Finally, we can close Rule Editor, save our Rule, and close Rule Designer.
To confirm that Delete Document action is not visible for Document entity we navigate back to the Designer Folder where our Document lives, select Manage option for the document, and observe that Delete Document Action is not in the list of available actions.