function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Doug ADoug A 

Approval Process: dynamically assign approvers

Is there a recommended approach for the using the API to assign approvers?  Here's our scenario:
 
We have an approval process that requires a manager, vice-president, and president's approval.  So, we have an approval process with three approval steps.
 
The manager and vice-president vary, so the corresponding user ids must be assigned programmatically.  (We cannot use the "Step 3. Select Assigned Approver" option to specify the user who should approve records that enter this step.  We also cannot allow either the submitter or the approving user to manually choose the next user.)
 
What's the recommended approach here?
 
 
Doug ADoug A
Perhaps a better question would have been, "is it possible to dynamically assign approvers to the steps in an approval process?" 

At this point, any workable guidance would be appreciated.


Doug ADoug A
In my ongoing trials, I've come up with an approach to effectively dynamically assign approvers.  It's led to a minor realization: a single approval process cannot contain some steps which "Let the submitter choose the approver manually" and other steps which "Automatically assign using the custom field selected earlier." 

This has required a bit of a workaround -- ie, combining an auto-assignment to a specified user, sending an outbound message, then programmatically reassigning a ProcessInstanceWorkItem.

Are there any plans on the roadmap to enable approval processes to contain both methods of approver assignment: manually and using a custom field?

Thanks.

Update: Apparently an approval process can indeed contain both methods of approver assignment.  In some cases, however, this ability is removed from an approval process, and even clones of that approval process will be constrained to one method of approver assignment (either auto-assigned or manually-assigned, but both options will not be available for new steps).  The fix is to create a new approval process, rather than clone an existing one.


Message Edited by Doug A on 01-17-2007 02:23 PM

RajaramRajaram
Doug,
Set up a custom hierarchy filed for each user which maps to you hierarchy.

So John is the person submitting the record for approval.
Mike is the VP.
Dave is the President

SoThe custom hierarchy field "Manager" for John will be set to "Mike"
Mike's custom hierarchy will be set to "Dave"

In other words, you can build the approval hierarchy and let the approvals engine use this information.

Hope this helps.
narensnarens

Hi Doug,

   How you were able to use "User Hierarchy" for auto approval? In your use case, is every approver, after approving, sends the "approval request" to his/her boss by clicking the "Submit for approval" button. If yes, i understand how this is implemented.

 

But in our use case, after the approval , new approval request should be automatically sent to the next one in the hierarchy automatically. Any ideas, how this can be implemented?

 

Thanks for your help in advance.

 

narens