Forum Discussion

LukasSliuzas's avatar
LukasSliuzas
Copper Contributor
Apr 20, 2020
Solved

Item approval, reassign and input

Hello,

 

I am new user who is learning how to use Office 365 package. While trying different features I noticed that I can't do most common thing which is launch an approval which has:

  • Option to reassign to somebody else.
  • Put information to custom fields

I will try to explain what I am trying to achieve. On SP2013 I used to have a list for example with three fields. Field1 and Field2 would be filled out by User1. When User1 submits the item then automatic WF would send an approval link to User2 where he can review the information and write information into Field3 which would be automatically updated inside WF and then into the list. How could I achieve that?

Input into Field3 I could achieve using maybe Microsoft Forms? Right now I can't find a simple solution for that. Thank you for your time and I will be waiting any kind of help. 

 

Ps if you have any question let me know and I will try to answer them in as much as detail I can

  • LukasSliuzas  yes you can, you can do this with a flow in Power Automate which will get the response from a form or a new item added to a SharePoint list, check the department and send an email to the appropriate approver which they approve/reject inside the email and the flow then updates the item in the SharePoint list with the decision details and any comments made by the approver .

     

    In this example I have a separate list with an approver based on department:

     

     

    The main list has a form for a request and the requestor selects their department:

     

     

    In Power Automate, start with an instant flow - from blank then just click skip and an empty flow will open. In every flow you need 1 trigger then at least 1 action. For your trigger select a SharePoint When a new item is created. You select the site and the list. Next add an Initialize variable and set it to string and I've named it varDepartment as it will hold the department value in the request.  You select that from the dynamic content box which appears when you click in the Value field.

     

     

    We only want to get the appropriate approver from the approvers list, so next add a SharePoint Get items action, show the advanced options and in the Filter Query field type Title eq '{varDepartment}' note you need the single quotes. So this filter query is saying if the department in the Title column of the approvers list equals the department in the variable then get it, otherwise ignore it.

     

     

    Then add a Start and wait for an approval action. It will wrap itself in an apply to each control which is no problem. Select First to respond for the approval type and add a title. In the Assigned to field select the Approver column from the Get items section of the dynamic content as that holds the relevant email adddress. Add in the text you want to go into the approval request and select any of the other dynamic fields you want to show in the email; in this case I'll display the department making the request and the request itself.

     

     

    Finally, add a SharePoint Update item action to update the main list with the outcome of the approval, who did the approval, the date they did it and any comments they made. It will, again, wrap itself in an apply to each which is OK.

     

     

    The email goes to the approver,. It's what's called an adaptive card which means that the approver doesn't need to go to the list to approve the request but can do so in the email itself. They select Approve or Reject and then can add any comments.

     

     

    When they click Submit the adaptive card closes so they can't approve it again:

     

     

    The SharePoint list gets updated:

     

     

    Approvers can't re-assign an approval from within the email itself, it would need to be done on Power Automate site.

     

    I hope that helps but come back with any questions.

     

    Rob
    Los Gallardos

    Microsoft Power Automate Community Super User

     

  • RobElliott's avatar
    RobElliott
    Silver Contributor

    LukasSliuzas  yes you can, you can do this with a flow in Power Automate which will get the response from a form or a new item added to a SharePoint list, check the department and send an email to the appropriate approver which they approve/reject inside the email and the flow then updates the item in the SharePoint list with the decision details and any comments made by the approver .

     

    In this example I have a separate list with an approver based on department:

     

     

    The main list has a form for a request and the requestor selects their department:

     

     

    In Power Automate, start with an instant flow - from blank then just click skip and an empty flow will open. In every flow you need 1 trigger then at least 1 action. For your trigger select a SharePoint When a new item is created. You select the site and the list. Next add an Initialize variable and set it to string and I've named it varDepartment as it will hold the department value in the request.  You select that from the dynamic content box which appears when you click in the Value field.

     

     

    We only want to get the appropriate approver from the approvers list, so next add a SharePoint Get items action, show the advanced options and in the Filter Query field type Title eq '{varDepartment}' note you need the single quotes. So this filter query is saying if the department in the Title column of the approvers list equals the department in the variable then get it, otherwise ignore it.

     

     

    Then add a Start and wait for an approval action. It will wrap itself in an apply to each control which is no problem. Select First to respond for the approval type and add a title. In the Assigned to field select the Approver column from the Get items section of the dynamic content as that holds the relevant email adddress. Add in the text you want to go into the approval request and select any of the other dynamic fields you want to show in the email; in this case I'll display the department making the request and the request itself.

     

     

    Finally, add a SharePoint Update item action to update the main list with the outcome of the approval, who did the approval, the date they did it and any comments they made. It will, again, wrap itself in an apply to each which is OK.

     

     

    The email goes to the approver,. It's what's called an adaptive card which means that the approver doesn't need to go to the list to approve the request but can do so in the email itself. They select Approve or Reject and then can add any comments.

     

     

    When they click Submit the adaptive card closes so they can't approve it again:

     

     

    The SharePoint list gets updated:

     

     

    Approvers can't re-assign an approval from within the email itself, it would need to be done on Power Automate site.

     

    I hope that helps but come back with any questions.

     

    Rob
    Los Gallardos

    Microsoft Power Automate Community Super User

     

    • LukasSliuzas's avatar
      LukasSliuzas
      Copper Contributor

      Hello RobElliott 

       

      Thank you for your response but that isn't want I am looking. I need data placed from PowerApps form to list. Currently I am stuck on how to check if field is empty?

Resources