cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper I
Helper I

Need help in converting 2010 Leave Approval WF to Flow.

Dear All,

 

I am trying to work on a flow based on the following multiple conditions with an existing old Workflow.

 

The Conditions for existing workflow are as follows for a leave workflow:

 

 

Eswar1_0-1595636191216.png

 

Eswar1_1-1595636279802.png

Eswar1_2-1595636326975.png

I cant use a default approval template as this functionality is customized.

 

I have tried the following flow with conditions & need some help with the flow I have created

 

The following is the flow.

 

 

Eswar1_4-1595636984501.png

 

2) Expanding the Line Manger Email Not Sent condition.

Eswar1_5-1595637093554.png

 

Here I want to set the column value to Yes, once the Mail is sent same as 2010 Workflow.

 

3) 

Eswar1_6-1595637236688.png

 

As seen in 2010 Workflow there is a option of If else conditions here I am able to keep only few conditions and also Set EMail sent value should be checked.

 

I need help in completing this workflow with if else conditions, as of now I am using multiple ifs also Set EMail sent value should be checked.

 

4) 

Eswar1_7-1595637592920.png

 

 

5) 

Eswar1_8-1595637678864.png

 

 

(As there are multiple conditions I am facing difficulty in keeping multiple IF conditions, please help me with the flow).

 

Many Thanks.

Eswar

 

5 REPLIES 5
Dual Super User III
Dual Super User III

I would replace all the If/ElseIf statements with a switch.  You may have to save the status first as a string variable, but that would clean up the logic a lot.  A lot of the rest then becomes simple If conditions under the appropriate branch for the switch.  The one exception is that you probably want to have a condition first that checks ApprovalConditionAccepted to bypass the switch if its NO



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Can you please show it in a flow in a few steps.

 

Many Thanks.

Dual Super User III
Dual Super User III

Here are some screenshots to give you an idea

Overall

image.png

Beginning Logic (trigger on created or modified, save status as a string, check to see if ApprovalConditionAccepted

image.png

Then Switch based on the current status If ApprovalConditionAccepted is Yes

image.png

Then under each switch do the logic for that status setting - Pending Line Managers approval as an example

image.png

I don't have a list with all the columns you reference in your 2010 workflow, but hopefully this gives you an idea.

 



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Dear Pstork1,

Thanks for the steps provided could you please elaborate how to use set values in the flow & then use the Switch Statement.

Please find the column names of the list :

 

Eswar1_0-1596086934992.png

 

Eswar1_1-1596086992952.png

 

 

Conditions :

 

Eswar1_2-1596087072573.png

Eswar1_3-1596087105501.png

Eswar1_4-1596087152854.png

 

 

Thanks,

Eswar

Dual Super User III
Dual Super User III

The values you need are already in the dynamic content dialogue box for the flow.  You just plug them in to the right fields in the actions.  If you aren't sure how to do that I would suggest starting with some basic Power Automate tutorials.

 

https://docs.microsoft.com/en-us/learn/modules/introduction-power-automate/



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Helpful resources

Announcements
PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Users online (2,891)