Friday, March 9, 2018

Creating a New Hire Workflow...Using Tasks Created Dynamically from a SharePoint List

The following describes how to create a workflow that uses tasks that are updated in a regular SharePoint list, allowing your end users to create/edit/remove/assign tasks in a SharePoint list, so they never have to open up SharePoint Designer.

It's a process I like to use for a new hire process or for offboarding, or any situation where tasks tend to change regularly.

It essentially involves building:
  • New Hire list - this is the list your users will be filling out to kick off the new process, and contain all the information about the new hire
  • Task Administration list - Create a custom list that will store the tasks we want to be created when the workflow runs
  • Tasks list - that will store the tasks that will get created and assigned to users
  • Workflow - loops through each item and assigns the tasks to the users at runtime

and the process is:
  • Somebody fills out a form to add a new hire
  • This kicks off the workflow
  • The workflow loops through the Task Administration list, creating tasks in the Tasks list
  • Everyone assigned a task gets an email at the end

New Hire List List

The new hire list collects the information about the new hire, and kicks off the process.  


Task Administration List

The Task Administration list is just a custom list with the following fields: 
  • Title - this will be the name of the task that will get created, e.g. "Create AD Account"
  • Assigned To - this is the person or group the task will be assigned to
  • Task Type - [Task or Notification] - I use this to distinguish if I should create a task, or just send an email notification
  • Task Active For - [Employees & Non-Employees, Employees or Non-Employees] - this determines whether the task should get assigned for different categories of users


Tasks List

The Tasks list is just an OOB Task list:

Workflow

The workflow essentially just queries our Task Admin List, loops through each item, creates a task, and keeps a running list of who to email at the end (so everyone gets just one email no matter how many tasks are create for them).

In this example I also added two extra bits of functionality:
  • I added a "Task Active For" column in the Task Admin list, which specifies if a task is needed for Employees, Non-Employees, or both.  The workflow checks this and assigns tasks accordingly
  • I also added a "Task Type" column in the Task Admin list.  If marked as a Task, a task gets created.  If a Notification, it just sends an email to the users assigned, and no task is created.

1 comment:

Anonymous said...

Good Stuff. Lots of helpful examples that I will use in creating my new hire wrkflows