Close RITM and Request when all catalog tasks are closed

Samiksha2
Mega Sage

Hi All,

 

I have below requirement:

All Tasks are Closed Complete – RITM and Request Closed Complete.

All Tasks are Closed Incomplete – RITM and Request Closed Incomplete.

All Tasks are Closed Skipped – RITM and Request Closed Skipped.

 

If it is a mix, then:

If any are Closed Complete, then RITM and Request Closed Complete

Else RITM and Request Closed Incomplete

 

I tried to do with Flow designer but it is updating only one state i.e Closed Complete

Samiksha2_1-1695867951134.png

 

 

Please help me in the above logics in FD or with any script.

Thanks,

Samiksha

1 ACCEPTED SOLUTION

@Samiksha2 create another variable called "anyClosed" and in the for each step add an if condition, if task status is closed complete set anyClosed variable to true.

 

Then after the for loop your conditions will be like below,

 

if - anyClosed :: is :: true -- Set the status to Closed Complete

else if - first variable :: is :: closed complete -- Set the status to Closed Complete

else if - first variable :: is :: closed Incomplete -- Set the status to Closed Incomplete

else if- first variable :: is :: closed skipped -- Set the status to Closed Skipped

 

Please mark my answer helpful and accept as solution if it helped you 👍✔️

Thanks,
Anvesh

View solution in original post

13 REPLIES 13

AnveshKumar M
Tera Sage
Tera Sage

Hi @Samiksha2 

In your flow create a flow variable, and within for each loop (Step 6) set the variable value to Status (Closed Complete, Closed Skipped, Closed Incomplete etc.) of Task (after Step 7).

 

Then after the for each step, check for the value of Flow variable using an If , else if and else condition and set the Status of RITM and Request accordingly.

 

Please mark my answer helpful and accept as solution if it helped you 👍

Thanks,
Anvesh

Hi @AnveshKumar M ,

 

Thank you!!
It is working fine for the below conditions:

All Tasks are Closed Complete – RITM and Request Closed Complete.

All Tasks are Closed Incomplete – RITM and Request Closed Incomplete.

All Tasks are Closed Skipped – RITM and Request Closed Skipped.

 

But for If any are Closed Complete, then RITM and Request Closed Complete, it is closed incomplete.

How to add logics for the above condition

 

Thanks,

Samiksha

@Samiksha2 create another variable called "anyClosed" and in the for each step add an if condition, if task status is closed complete set anyClosed variable to true.

 

Then after the for loop your conditions will be like below,

 

if - anyClosed :: is :: true -- Set the status to Closed Complete

else if - first variable :: is :: closed complete -- Set the status to Closed Complete

else if - first variable :: is :: closed Incomplete -- Set the status to Closed Incomplete

else if- first variable :: is :: closed skipped -- Set the status to Closed Skipped

 

Please mark my answer helpful and accept as solution if it helped you 👍✔️

Thanks,
Anvesh

Hi @AnveshKumar M ,

Thank you so much. It is working as expected. Evening I will give demo if any help needed I will open this thread again.


Thanks,

Samiksha