Forum Discussion
Flow is behaving wierd
- Feb 05, 2019
Hi Adam,
Have you got the chance to view the issue?
Hi
I am sending the screen shot of the Flow.
In my flow when a file is added or modified, it should trigger.
I have made the Content Approval Settings on.
My requirement is according to the classification (Custom choice Field) selection, it goes approval managers to approve the document.
The flow i did as follows:
1. Call the action when the file is added or modified.
2. Get the File Metadata (here in the FileIdentifier i added Identifier value)
3. Initialize the classification variable
4. Set the variable of Classification which i selected from the form.
5. Check the condition if the document uploaded needs Approval process, as we have the requirement that all the documents should not go for the approval process.
6. Switch action to start the approval process according to the classification selected.
7. For the case "Architecture" , i call the content approval status to set the the Approval Status as "pending".
8. call the "Start an Approval" .
9. Condition to check the Response.
a. If Response is "Approve", again call the content approval status to set the value as "Approved"
b. Send the mail.
c. If Response is "Reject", again call the content approval status to set the value as "Reject"
d. Send the mail.
Now the issue is suppose i added a file, with all my valid metadata, it starts the Approval process, and its status is "Pending" , sending a mail
Now again i add 2nd new file, it starts the approval process and its status is "Pending" , and send an approval mail to the approver, but at the same time a new instance of previous item, flow starts the approval process, and a mail is sent again for the previous item.
But if i status is "Approved" after approving by the approver, that items instance is not triggering.
Hence, if there are 2 files which is "Pending " state, and third file is added into the library, 3 approval mails are recieved or 3 instance is creating.
But if there are 2 files , one is "Pending " and other is "Approved" and a third file is added in the library, 2 approval mails are recieved or 2 instance is created.
Appreciate your help to figure out my mistake.
Hi!
I'll try have a look at this as soon as possible! It's a busy day at the office today :)
In the meantime, I would suggest also posting this in the flow community:
https://powerusers.microsoft.com/t5/Microsoft-Flow-Community/ct-p/FlowCommunity
just Copy / paste the last post in there!
/ Adam
/ Adam
- Asesh Kumar MaityFeb 05, 2019Brass Contributor
Hi Adam,
I had communicated with the flow power community as you suggested.
They suggested to check the status and restrict to call, before the Start an Approval action.
The details url of discussion
https://powerusers.microsoft.com/t5/General-Flow-Discussion/Approval-Flow-is-Behaving-Wierd/m-p/214025#M20341
I guess the suggestion is the way around, but there will be always a new instances will be created for each and every created or modified items, which are Pending or Draft state.
I need to understand why every time the flow is creating a new instances if the item is in Pending or Draft state.
Appreciate your help for the same. Is it the built in behavior of the Action or I made a mistake?
Thanks and Regards
Asesh
- Feb 05, 2019
No, unfortunately not :( Any responses on the flow community??
- Asesh Kumar MaityFeb 05, 2019Brass Contributor
Hi Adam,
Have you got the chance to view the issue?
- Asesh Kumar MaityFeb 04, 2019Brass ContributorThanks Adam, i send the query to the Flow Community as you suggested in your last Post.