r/PowerAutomate • u/NullReferenceGhost • 8d ago
Approval Flows/Child Flows
Hi! I have two questions if anyone knows the answer or can point in the right direction or even have an idea.
My approval flow is very reactive which means I need to know someone approval or rejects it and go on if I get the right number of yes or no.
1.With that I have child flows running even though the parent flow is done. Anyone I can cancel those running child flows once the parent is done or let them cancel out on their own?
- With the approval/reminder the user gets notified via email and teams via the approval app.
Is there a way I can mark that approval as done or close once the parent flow is done? as people think that there is still an open approval and they respond and don’t realize that’s been done for a week now.
1
u/HoldPowerful7487 8d ago
Two separate things going on here.
For the stale approvals sitting in people's Approvals app, cancelling the flow run that created them clears them out. You can do that straight from the run history of the child flow, select the running ones and cancel. If you want it automated then yeah, you're into the Dataverse approvals table like robofski said, and that's premium.
The bigger fix is the design though. If your child flows exist just to run one approval each, you probably don't need them. Start and wait for an approval already takes multiple assignees, and the Custom Responses type with wait for all responses hands you everyone's answer in one action. One run to cancel instead of eight.
If you actually need a quorum, like three yes out of five and then stop, split it into Create an approval and Wait for an approval and put the waits in parallel branches in the parent. Parent keeps control and there are no orphans to chase later.
1
u/robofski 8d ago
I do something similar where I have an approval that has to be actioned by the last day of the month or it is cancelled. I record the approval ID on a SharePoint list where I also record the approval request and outcome etc, and then on the 1st of the month I select all records from that list where the approval is still pending and I update the approvals table in dataverse (premium connector required) to cancel the approval so the user can no longer interact with it. I also cancel the flow run.