cancel
Showing results for 
Search instead for 
Did you mean: 

Making the work flow user specific

kiran_428
Champ in-the-making
Champ in-the-making
Hi friends ,

I am facing a problem in cteating a simple work flow.I have created a rule ..for submit for approval..but it should only be seen by a user called agent .But a user called underwriter is also able to see.So my requirement  is ..only Agent should see that …so can I write a rule that is user specific..

Thanks in advance,
Kiran.
1 REPLY 1

jpotts
World-Class Innovator
World-Class Innovator
You are saying "rule" but I assume you mean "UI Action". I don't think it makes sense to hide rules from users but it would definitely make sense to hide UI actions from users based on their role or any other arbitrary criteria.

If you are talking about UI actions, you have two options. First, you can use the "permissions" element to define the minimum set of permissions a user must have in order to see the UI action. The permission group you use can be an out-of-the-box permission group like, "Editor" or "Coordinator", or it can be a custom one that you define, like "Agent".

Your second option is to write an action evaluator class. Action evaluators implement the org.alfresco.web.action.ActionEvaluator interface. Your evaluate method returns true or false to tell Alfresco to show or hide the UI action. You can use whatever logic you want in your evaluate method.

Of course, you can combine both if you need to.

Here is a sample UI action config from the Alfresco Developer Guide that shows a UI action that is only visible to members of the custom "PortalPublisher" role when the com.someco.action.evaluator.WebEnableEvaluator's evaluate method returns true:

<action id="web_enable">
<permissions>
<!– each permission can be an Allow or Deny check –>
<permission allow="true">PortalPublisher</permission>
</permissions>
<evaluator>com.someco.action.evaluator.WebEnableEvaluator
</evaluator>
<label-id>enableWeb</label-id>

</action>

Jeff