web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Tracking approvals fro...
Power Automate
Unanswered

Tracking approvals from multiple users in a document library

(0) ShareShare
ReportReport
Posted on by

Hello, 

I am building a workflow from a SP document library where multiple users need to approve documents once they are out of the draft stage and submitted for approval (i.e. 'Pending'). The workflow is able to send the approval request out to each user using "Start and wait for an approval" and is specified "custom responses - Wait for all responses". Note: users will change on each document, so I am using dynamic content to set the approvers with their email. However, the status of the document is automatically updated to "approved" when the first user responds. I created a "somewhat" workaround, where each users approval gets listed in another column using a string variable, but this makes the properties of the document change and then it reverts to a draft status. I am not using this workaround as it defeats the purpose of having the approval status in the first place.

 

The flow is as follows:

 

Trigger: When an item or file is modified

Trigger Condition- @equals(triggerOutputs()?['body/{ModerationStatus}'],'Pending')

 

Get file properties

 

Get file metadata 

 

ksod_0-1659976284824.png

 

ksod_1-1659976319676.png

ksod_2-1659976350034.png

ksod_3-1659976396173.png

 

ksod_4-1659976436735.png

 

 

I am very new to Power Automate, so any feedback on this will be useful. It would be great if the status could remain pending until all users have approved the document or at the very least - let me know who has approved/hasn't approved without reverting the status to 'Draft'. 

 

Thanks, 

ksod

 

 

 

 

 

Categories:
I have the same question (0)
  • Verified answer
    Ed Gonzales Profile Picture
    4,531 Most Valuable Professional on at

    @Anonymous 

    Hey there....so here's what's happening (great work so far, btw!)

     

    The variable that you've created for the approvals is an Array (list), so when you create the approval and listed that variable as the assigned to, Power Automate automatically kicked off an Apply to Each loop.  So, it starts working through your list of approvers and creates a different approval for each one.  That's why the first one to approve kicks off all of the "approved" stuff.

     

    The fix is to shift that variable to a String, and append each new name with a semi-colon in between.   That way, Power Automate won't put it inside a loop, and will create a single Approval with multiple people rather than multiple approvals with just one person on it.

     

    Once you do that, you will only have a single "Outcome" so you can get rid of that variable and that loop, right?

     

    Hopefully, that's enough to move your game piece to the next square.   Good luck, and keep us posted.

     

    -Ed

     

    If you liked this reply, please give it a thumbs up! If this reply has answered your question or resolved your challenge, please consider marking it as a Solution. This helps other users find it more easily via search.

  • Verified answer
    Community Power Platform Member Profile Picture
    on at

    Ed, 

     

    Ah! This worked. Here's how I did it. Now, the status remains 'Pending' until all approvers have responded! I still have the responses "apply to each" so that I receive a teams message with each approval, but that can be changed as well.

     

    ksod_0-1660055157237.png

     

    Thank you for your help, I was stuck on this for a while!! 

     

    - Kristen

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard