In the previous article, I discussed some ideas behind the SharePoint workflow designer custom task process and how SharePoint 2010 and SharePoint 2013 support this feature.
In this article I will develop a simple approval workflow based on custom task process in SharePoint 2013 using SharePoint designer 2013, but with SharePoint 2010 workflow engine!
You can find the link to all posts here.
It is a good idea to always document what you want to accomplish on SharePoint designer workflow in Microsoft Visio or other diagraming tools. The good thing about using the Microsoft Visio to create the workflow diagram is if you use the right stencil, you can export your developed diagram out of Microsoft Visio and import it to Microsoft SharePoint designer workflow.
For example, this is the diagram of our workflow in Microsoft Visio:
Figure 1 – Approval workflow
In this walkthrough, we will go step by step to complete developing this workflow.
- Open Microsoft SharePoint Designer, load the SharePoint site, select List and Libraries, select the list you want to associate the workflow with (in my case there is a list named Contract) and click on the New workflow button.
Figure 2 – new workflow in SharePoint workflow designer
- Name the workflow (Contract Approval) and select SharePoint 2010 workflow from Platform type
Figure 3 – name workflow and select type
- Select Action in the Ribbon and then select Start custom task process under Task actions. Now you have a custom task process in your workflow. The name of the task process (in my case Task(3)) may be different for you
Figure 4 – add custom task process
- Click on “these users” to enter participants and other task information. This page is about configuring values of individual tasks of the whole task process.
Figure 5 – participants
- You select the name of participants here.
- If you want to CC tasks to other people in the organization, enter it here
- You can determine whether you want to send tasks to participants serially or in parallel. In our own example we want to send tasks serially.
- By clicking on this button you can add another assignment stage in your workflow. For example I enter three different stages and place one user in each stage. Because all of my tasks are going to users in serial mode, it is possible to enter all of them in one box and select the serial in the box number 3. You can also have the combination of serial and parallel task assignment stages.
- Enter title of all tasks here, you can use formula too
- Enter the description of all tasks here, you can also use formula to create custom description
- Enter the duration of each tasks here. After passing the due date, the task will go into the expire mode
- Enter the due date for all tasks in the task process. After this time all tasks will goes to the expire state
Figure 6 – task complete
- Now click on your task process name (Task(3)) to enter the task process configuration page.
Figure 7 Task Process configuration page
- I want to change the completion condition of the task process, click on the link to enter the completion condition page
Figure 8 click on the link
Figure 9 – completion criteria
- Enter the criteria to stop the task process if the number of rejection is equal to one. It means whenever even one participant reject the task, the whole task process will end and the process goes out of the task process
Figure 10 – select the criteria
Figure 11 – complete condition
- After that you can publish the workflow and use it on your site