You need to sign in to do that
Don't have an account?

Creating Parallel Approval Processes
I need to create several approvals on an Opportunity before it is marked as "Closed Won".
The approvals needed are the following -
1. Sales Manager to approve any discounts of products
2. Inventory Mgr to approve availability of products
3. Finance to approve pricing & discounts of products as well.
These approvals can happen in parallel by different users belonging to the 3 different divisions - Sales, Finance, and Operations.
I tried creating multiple Approval Processes for Sales, Inventory and Finance but since they are all associated with the Opportunity object - so only 1 of the Approval process is getting triggered. Using Approval Steps make it a serial process?
Any idea how I could implement this?
The approvals needed are the following -
1. Sales Manager to approve any discounts of products
2. Inventory Mgr to approve availability of products
3. Finance to approve pricing & discounts of products as well.
These approvals can happen in parallel by different users belonging to the 3 different divisions - Sales, Finance, and Operations.
I tried creating multiple Approval Processes for Sales, Inventory and Finance but since they are all associated with the Opportunity object - so only 1 of the Approval process is getting triggered. Using Approval Steps make it a serial process?
Any idea how I could implement this?
It's hard to provide more guidance without knowing more specifics about your approvals.
Message Edited by Scott Jorgensen on 10-06-2008 10:44 AM
Hi I am trying to update the in processinstance status comment in case of parallel approver. when one approves the other should be approved and put the comment for 2nd approver. and go to the next step for approval.
my code as follows
ProcessInstanceWorkitem[] wi = [
Select p.ProcessInstance.Status, p.ProcessInstance.TargetObjectId,p.ProcessInstanceId,
p.OriginalActorId,
p.Id,
p.ActorId From ProcessInstanceWorkitem pwhere p.ProcessInstance.TargetObjectId = : qId
and p.OriginalActorId ='00550000000lfOD'];req.setComments('Approved-test');
Id wId;
if (wi.size() > 0){System.debug('testapprove1');wId= wi[0].Id;
}
req.setWorkitemId(wId);
if(wId!=null){Approval.ProcessResult result = Approval.process(req);
}
when I approve for one it creates another record with pending..
is there anything wrong.?
Any help on this would be appriciated.