and more in a single search tool across platforms. Read the announcement here. |
02/16/2024 01:27 AM
Greetings everyone,
I am working on use case,
When an enterprise role is requested for a role owner as the beneficiary, the approval should be sent to the other role owners in the group along with the beneficiary’s line manager.
For example: User1 is the role owner for role1. There are other role owners (User2, User3) to the role1. When role1 is requested for User1, the request should be sent for User2, User3 & User4(line manager of User1)
I want to know how to achieve this.
Solved! Go to Solution.
02/16/2024 02:08 AM
Hi @Smiling
Try using a custom query. something along the following lines for routing the approval to other role owners:
select userkey from role_owners where rolekey=${REQUESTACCESSOBJ.id} and userkey!=${user.id}
Workflow Components (saviyntcloud.com)
02/16/2024 03:05 AM
Hi @Smiling , you need to do this in 2 steps if I have understood your ask correctly.
1) if else condition sample for ents (entitlement.getOwnerRank1().contains(user.username) eq true or entitlement.getOwnerRank1().contains(requestedby.username))
2)If above is true meaning this is user 1 , then use a custom assignment to get role owner and
select userkey from role_owners where rolekey=${REQUESTACCESSOBJ.id} and (userkey!=${user.id} or userkey!=${RequestedBy})
3) If false - go to normal access approval block.
Please feel free to change queries where needed but overall this is how you can structure the flow.
Best Regards,
Amit
02/18/2024 08:23 PM
Hey Guys,
Thanks for your help but how's workflow going to look like.
02/19/2024 06:44 PM - edited 02/22/2024 06:39 AM
Query
select userkey from role_owners where rolekey=${REQUESTACCESSOBJ.id} and userkey!=${user.id}
union select manager as userkey from users where userkey =${user.id} and ${user.id} not in (select userkey from role_owners where rolekey=${REQUESTACCESSOBJ.id})
02/21/2024 09:06 PM
hey @rushikeshvartak,
After request is accepted by line manger it is escalating to admin not role owner, do you know why it is happening?
02/21/2024 09:30 PM
Share wf
02/21/2024 09:53 PM
02/21/2024 10:02 PM
I dont see any escalations in wf
02/21/2024 10:13 PM
I meant to say the request should go to role owners right, but it is going to admin IDK why?
02/22/2024 12:05 AM - edited 02/22/2024 12:06 AM
Hi @Smiling There is a small typo in the query which is causing it to assign to admin.
select userkey from role_owners where rolekey=${REQUESTACCESSOBJ.id} and userkey!=${user.id}
union select manager as userkey from users where userkey =${user.id} and ${user.id} not in (select userkey from role_owners where rolekey=${REQUESTACCESSOBJ.id})
The closing curly braces was missing in the above condition in the inner query.
${REQUESTACCESSOBJ.id}
Let me know if the above query helps!
02/28/2024 08:30 PM
hey Thanks for help
now requirement is, needed separate if else condition box where if request is raised for role owner then and only then it will go for custom assignment where if it is requested for role owner then except him request should go to other role owners.
02/28/2024 08:51 PM
select userkey from role_owners where rolekey=${REQUESTACCESSOBJ.id} and userkey!=${user.id}
Custom query block
If else
role.getOwnerRank1().contains(user.username) eq true