Workflow stage issue

mitzaka
Mega Guru

Hi SNC,

 

I am stuck with a workflow here. What I have is a workflow over sc_req_item table. I have my own stage set and I am using custom stages - submitted, assigned, under investigation, etc. The first couple of steps of my workflow are to set the Stage to Submitted once someone creates a catalog request. Then the second activity is to create a catalog task which is in the related lists of the RITM records.

 

The beginning of it looks like this:

find_real_file.png

 

What I want to do next it to check if this catalog task is assigned to anyone, and if so then set the stage of the workflow to Assigned. So my two issues here are:

 

1. when I submit a request, the stage default first state still shows 'Approved', and then Submitted (my custom). I believe this is based on the fact that the default dictionary value is 'waiting_for_approval' and maybe something picks this up and sets the Approved stage. So how do I make the default to Submitted.

 

2. In my workflow activity which checks for the task assignee, I am using a WAIT FOR CONDITION activity with the condition 'delivery task.assigned to' is not empty

find_real_file.png

 

But it's not working. Even when I assign the task, the stage of the RITM still says Submitted. So is Delivery Task the right thing to use for this condition?

1 ACCEPTED SOLUTION

randrews
Tera Guru

ok your issue is that the stage setter isn't going to be hit till AFTER the catalog task is set because they are linear... try this...



put a branch before the catalog task and a join after.. set the branchs stage to the same as the task.. and set the join's stage to "Assigned" so that when the join is hit the stage will change to assigned.



now put the wait for you have to the same stage as the catalog task and coming out of the branch going to the join....



hopefully the wait for and task will kick off at the same time.. when the task is assigned the wait for will stop waiting go to the join and trigger the stage change... you may have to put a small <1 minute> timer in front of the wait for to allow the task to be created.


View solution in original post

7 REPLIES 7

randrews
Tera Guru

ok your issue is that the stage setter isn't going to be hit till AFTER the catalog task is set because they are linear... try this...



put a branch before the catalog task and a join after.. set the branchs stage to the same as the task.. and set the join's stage to "Assigned" so that when the join is hit the stage will change to assigned.



now put the wait for you have to the same stage as the catalog task and coming out of the branch going to the join....



hopefully the wait for and task will kick off at the same time.. when the task is assigned the wait for will stop waiting go to the join and trigger the stage change... you may have to put a small <1 minute> timer in front of the wait for to allow the task to be created.


Doug Andrews - this worked just like you described it. Thanks!


no worries at all glad it worked for you