Join Gini von Courter for an in-depth discussion in this video Create an approval flow, part of Learning Microsoft Flow 2017.
- There are lots of business processes where everything grinds to a halt while we wait for someone to provide their approval, to sign off on a particular document so that it can be published or so that it can move to it's next stage. The approval flow is made for that situation. Here I am in SharePoint with a document selected if I wished and I can click flow, here's a flow we created previously for feedback. We're going to create a new flow and the flow we're going to create is the one that is often at the top of the list because it's very popular.
Request manager approval for the selected file. When I select that, I'm going to be taken to the flow portal. This is going to connect not just to SharePoint and to Office but it's also going to connect the approvals that are being tracked by Microsoft Flow. This particular flow is going to create an HTTP post URL at the time it is saved. There is nothing here for you and I to do anything with. But we will get information then.
We will get outputs from this trigger that we can use elsewhere. Next we have get item and the item that is going to be retrieved is going to come from the site, a particular list, and the entity ID of this particular document. Nothing that I want to change here because I started in the right place. Flow is then going to get a profile and get manager and if we look at this, what it's actually got is the user principle name UPN.
You would think of that as your long email address that has your email @ and your domain. Once we have the identity of the person we want to send an email to we start an approval and this is what this approval looks like. We have the file name and a link to the file all coming from that initial HTTP request that is being created from our SharePoint information. Assigned to that email is part of the dynamic content for get manager.
And the details basically are going to be the subject of the email please review this file and provide your approval. Now we have a condition. We have a condition because the ability to approve implies the ability to not approve or to reject. Notice that if it is yes, response is equal to approve. If yes, inform author of the approval. We're going to send an email that says that this particular file has been approved and includes some links.
So if yes, we are sending an email letting the author know that this has been approved and is ready to go and if not, then we are sending a notice of rejection. Not approved as the subject and in both cases we're sending back a link and we're sending back comments and those comments are coming from the approval center. Out of the approval that was received from the manager. I think we're all set. Let's save this flow. It says my flow was created, to exit click done. And we will be taken back to the flow portal.
But notice as we started creating this that we still have our SharePoint site running, we still have our document library open. These weren't replacement tabs, these were new tabs so we can easily get back to where we were a moment ago. This flow is on and if I go back to my flows, I'll see that this flow has been added, right here. When this flow runs, it will generate a new record here in the approval center but we won't see anything there until we run this flow.
This flow relies on as your active directory. The active directory that is sitting behind Office 365. Therefore, if your active directory does not include the ID for peoples' managers, this flow won't work for those folks. There are also some reported issues about how this flow works if people use email addresses that are different than the email addresses that are in active directory. But assuming that your active directory includes managers then this will work. And so that I can demonstrate it, I've actually changed active directory in this particular instance for a short period of time so that I am my own manager, as you'll see in the next movie.
- Summarize what a flow is and utilize the different types.
- Determine how to formulate a flow using a template.
- Explain how to test, edit and manage a flow.
- Construct a flow that adds a task.
- Identify how to manage and share flows.