cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Gaia
Regular Visitor

Change file property after approval/rejection

Hi,

 

I'm having trouble creating a flow for approval of documents and changing the file properties based on the outcome of the approval.

My flow is as follows:

1) For a selected file

2) Start and wait for an approval-Approve/Reject-Everyone must approve.

note- I have 3 persons in the organization that must approve a document before it's declared approved. If either rejects, then the document is declared rejected.

3) Condition based on the outcome - Approve

3.1) If Yes - change file property called "sign-off status" to Approved.

3.2) If No- Change "sign-off status" to REJECTED.

 

The problem with this flow is that it only works if there's only one person assigned for approval in step (2). if I assign more people then the flow seem to always end with step (3.2) regardless of the assignee's reply. I get a notification via Teams that all assignees approved and that the status of the approval is overall approved, yet the file property in SharePoint seems to be REJECTED.

 

What am I doing wrong? Is there a better way of displaying via SharePoint which file is approved and which is not?

 

Thanks for the help!

 

1 ACCEPTED SOLUTION

Accepted Solutions
Pstork1
Dual Super User III
Dual Super User III

I suspect you are testing the wrong thing in Outcome.  If there are three approvers and they all approve then Outcome will be "Approve, Approve, Approve".  So if you are testing Outcome = "Approve" then it will pick the No side.  I suspect that is what is happening.  I normally reverse the sides and check Outcome Contains "Reject".  That way if any of the approvers reject it will be rejected otherwise it will be approved.



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

View solution in original post

2 REPLIES 2
Pstork1
Dual Super User III
Dual Super User III

I suspect you are testing the wrong thing in Outcome.  If there are three approvers and they all approve then Outcome will be "Approve, Approve, Approve".  So if you are testing Outcome = "Approve" then it will pick the No side.  I suspect that is what is happening.  I normally reverse the sides and check Outcome Contains "Reject".  That way if any of the approvers reject it will be rejected otherwise it will be approved.



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

View solution in original post

Gaia
Regular Visitor

Hi,

 

Thanks for your answer!

 

I tried the Outcome equal to Approve, Approve, Approve and it indeed worked for when the document was approved by all three approvers, but if even one rejected then the flow would stop and the file property I tried to change was left blank.

Your other suggestion of reversing the sided and conditioning on outcome contains reject worked perfectly.

 

Thank you!

 

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Top Solution Authors
Users online (1,939)