6 Nov’17

D365 Business CentralApproval Workflow using Workflow User group in Microsoft Dynamics NAV

Introduction:

What is Workflow User group?
Workflow user group is a group of users under one group title in Workflows with the users’ number in a process sequence such as an approver chain.

To define an approval request to be not approved until multiple approvers in a approval chain have approved it, set up approvers with incremental sequence number.Here the approval request is sent to the user with highest sequence number i.e. 1. This user will have to approve the request then an approval will be sent to the next user with sequence number 2 and so on.

To define approval request is not approved until multiple equal approvers have approved it regardless of the hierarchy assign same sequence number to the users.Here the approval request is sent to all users in the group at the same time.

Here, both the approval requester and approver must be set up in the Approval User Setup.

This blog provides a step wise procedure how to create approval workflow using workflow user group.

Pre-requisites:

Microsoft Dynamics NAV 2017

Steps:

I’ll explain workflow user group using a scenario.

Scenario: 

A sales department has a group of two sales managers. An approval request must be sent to the sales managers if the sales order amount is greater than 4000 and even if one of the sales manager approves the request, the document should be released.
1. Create a workflow user group

  • Navigate to Workflow User group in the search bar in Dynamics NAV and click on New.
  • Enter the code and description for it. Insert the approver users with sequence number as 1

2. Create a new Sales Order Workflow

  • Open workflow using the path CRONUS International Ltd./Departments/Administration/Application Setup/Workflow/Workflows
  • Click on New Workflow from Template button from the ribbon. click on the Sales Documents category and select Sales order workflow
  • Here the Sales Order Approval Workflow opens. Click on the first event condition and add a condition on amount > 4000
  • The response of the first event sets the Sales order status to Pending approval, creates and sends the approval request to the approvers.

3. Set the Approver Type to Workflow User group

  •  We are using the approval type as workflow user group hence, we need to specify this group in the workflow.
  • Now click on the assist edit button of the first response and click on the third response line. By default the approver type is Salesperson/Purchaser
  • Select the Workflow User group from the Approver Type drop down and select the workflow user group code.
  • Now the approval request will be directly sent to the Workflow User group with code SALES MANAGER

4. Set the sales order workflow condition

  • Click on the second event ‘An approval request is approved’. Here we observe that the condition reads Pending approval :0 which means that when all the approver users approve the request i.e. when the the count of the pending approval is 0 then according to the response, release the document.
  • Now we want even if one of the approver users approves the request, the sales order document must be released. we’ll have to change the condition to Pending approval :1
  • Here when the approval request is sent to both the sales managers, the pending approval count is 2. Now when one of the sales manager approves the sales document the count decreases to pending approval:1hence when the one of the sales manager approves the sales order document the sales order is Released
  • Finally enable the workflow

5. Send an sales order approval request

  • Navigate to sales order and create a sales order greater than 4000 and click on send approval request.
  • Observer the status of the sales document changes to Pending Approval.
  • 10

  • Login Microsoft Dynamics NAV with the sales manager user credentials and navigate to ‘Request to Approve’
  • To view the sales order click on Open Record
  • To approve the order click on Approve. This will Release the sales order document.
  • To reject the order click on Reject. This will change the status to Open.
  • Comments can be added by clicking on comments.
  • The sales manager approves it and the document is approved thus the status changes to Released

Conclusion:

To summarize everything, create a sales order workflow from the template. Create a workflow user group and assign sequence number to 1. Set the condition of amount > 4000 and Pending approval to 1. Select approver type as Workflow user group and select the workflow user group code. Finally enable the workflow.

Written by

Chris D'Silva

Software Developer

2 thoughts on “Approval Workflow using Workflow User group in Microsoft Dynamics NAV”

  1. Hi,
    Its nicely explained. In another blog you have raised a query on workflow in case there are two level approval and in 1st level if the sender &the approver are same then system auto approves the entry. However after 1st auto approval, when the 2nd approver approves the document this step is not executing as per workflow setup and the document is still in Pending for approval state. This was your query in community.dynamics.com. Have you got any solution or workaround for this case?
    link “: https://community.dynamics.com/nav/f/34/t/227574

    1. Hi Pradeep,

      In the community question, we’ve mentioned that we created another workflow from scratch which resolved our issue.

      It seems that we were probably missing some step. Kindly refer the standard workflow and code.

      Let us know if you still face any issue.

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload the CAPTCHA.

Want to streamline your business processes?

  • This field is for validation purposes and should be left unchanged.

Recent Articles

  • Reading more then 10K records in D3FOE OData API

    11 July’ 2018

    Introduction: We all know Dynamics 365 Finance and Operations has limitation of 10K records to be fetched at a time usi...

    Read more
  • Paging in D365 Customer Engagement v9.0

    10 July’ 2018

    Introduction: The Xrm.retrieveMultipleRecords method is used to retrieve a collection of records in Dynamics 365 Custom...

    Read more
  • Set up Dynamics 365 connection in Microsoft Social Engagement

    10 July’ 2018

    Introduction: This blog explains how to Set up Dynamics 365 connection in Microsoft Social Engagement. Steps to be follo...

    Read more
  • Voice of the Customer failed to install

    10 July’ 2018

    Introduction: Many people face issues in installing Voice of Customer solution on v9 environment and trying repeatedly ...

    Read more
  • Scribe Insight AX as a Web Service Find Block issue

    10 July’ 2018

    Introduction: If we need to look up for any value from AX then we do it by using a Find Block in Scribe Insight Eg: Basi...

    Read more