Skip to main content

Hi all,

 

Going back a year, K2 setup a way for my Workflows to be authorised by Authorisers from different user groups.

 

So for example, a User from department A would get approval sent via Workflow to an AD Authoriser Group X

 

Problem is that this was fine when testing, but now in reality, i have 30+ departments, so that means i have to create 30 AD groups (per K2 form) and then manually add each AD group to the Workflow Destination Rule. - which has taken me ages....

 

Is there any other way of simplying this?

 

Is it possible to have just one AD Authoriser group per form and have all authorisers in there? Then when a user from department X submits a request, it only goes the the Authorisers within that AD group who belong to department X?

 

My current setup works, but it is resource and time consuming..... But it is how K2 recommended it as i also send Email Messages to the other Authorisers in department X to let them know when a request has been approved by one of them. The Email message is sent To: the AD Group email address....

 

-So having one AD group would mean just one email address for the AD group..... How can i email only the Department X users within that Group for example?

 

Appreciate any help with this....

Hey There


 


It is possible that you could set up the workflow to take the user who submitted the list, see what groups the user is in, and send it to that group. You would use the UMGroup and UMUser SmartObjects to do so. The problem would come if there are multiple groups that the user is in, as this would require you to find the correct group.


 


Ian


Hi,

 

Thanks for your reply, but i think you misunderstood.

 

It is not about what group the user is from, it's the "department". The request from user X has to somehow go into just one AD group and email the Approvers within that group that have the same department filed (from AD)......... is that possible?


Are you attempting to add all of the authorizer users from every department to a single AD group; then when UserA of department 'Human Resources' submits a request, it has to go to all users in this group that is a part of the 'Human Resources' department?


 


Would this work?


1.  UserA of department Sales logs a request


2.  Call the AD Service2 > ADUSer Smartobject > Get User Details to retrieve this user's department 'Human Resources' (store in data field)


3.  Then call the AD Service2 > ADUSer Smartobject > GetUsersByGroup method with 'GroupName' = your single AD group and with filter where "Department = tdepartment of UserA stored in DataLabel/Sales]; this will return all authorizers of that single AD group belonging to that department matching UserA


 


13839i6DCF19BC24F44C0C.png


Hi,

 

Thanks for the idea, so after one of the Authorsiers in the Sales department has approved the request, how do you then send an email via the workflow to the other people in the same AD group (who are in the Sales department) that they do not need to do anything as the item has been approved by one of the Sales approvers?

 

In the Email Event To field, how do i fill in the To field to send the email to only the Authorisers from the Sales department and NOT the whole AD group?

 

Thanks,

 

 


Hi,

If I understand your query correctly. I have the below suggestion perhaps not the best one!

If I'm allowed to create a table, lets a approvals managing table where in have three columns let's say userName, department and email address.

For instance department sales have three entries in the approvals table since sales department has 3 authorizes for task approvals.

In the workflow at each activity destination rule, we call the Smartobject which queries the approval managing table with filter parameter as User department. Remember to call Smartobject get list method so that it returns all authorizers information as destination users. Once the task is completed by any one of the authorizers, in the same activity level we will have email event to send an email to all department authorizers, to fetch their email address in the we again query the approvals table passing department has filter and email address as return property.
This approach you don't need to create multiple AD groups and in terms of managing approvals information is easy.

Cheers,
Prajwal Shambhu

Thanks all,

 

I will look into this. Originally K2 told me the only way to do this was to have an AD group for each Form and Each department.

 

Can anyone show me how to do this?

 

1) One AD Group for One Form

2) In that one AD Group, have Authorisers in there for all Departments (example, Departments A,B,C,D)

3) Then create a form that checks the Departement of the User (example User from Department A)

4) Then send the Approval to the above AD Group and only send it to Department A Authorisers in that AD Group

5) When the first Department A Authoriser approves the request, send an EMAIL to all other Department A Authorisers in AD Group

 

If you guys can help me with this, this will be amazing, it will mean I will no longer need to have 20+ AD Groups per Form

 

I need to accomplish this in K2 Studio using Workflow....

 

Can you guys help?

 

Thanks as always fellow K2'ers


Ok, i've got round to devoting some time this week to have a look at this issue.

 

I need this to be done via Workflow, i.e. k2 Studio, so once the user submits the form, it starts a Process (K2 Studio Workflow).

In my Process General Activity, destination set rule, how do i get the Approval to only go to Approvers in that AD group from the same Department as the User?

 

I only want one Destination Set and all approvers from all departments in that ONE AD group....


Reply