Contributed by: Michael Wells, System Administrator, Chesterfield County, VA

With the holiday season rolling around, many organizations and departments have an annual Secret Santa tradition. With dozens of people participating, such a process can include a lot of coordination. To demonstrate the capabilities of Laserfiche at a recent user group meeting, I automated the whole gift assigning process with Laserfiche Forms and Laserfiche Workflow.

The process in a nutshell

The Secret Santa process at Chesterfield County works as follows:

  • Every employee who wishes to participate submits a Laserfiche Form that asks for their gift preferences.
    secret_santa1
  • Once all participants have submitted the questionnaires, the Secret Santa coordinator starts a Laserfiche Workflow business process that randomly assigns a participant to each list.
  • Each participant is notified by email of the person that they are assigned to purchase a gift for.secret_santa2
  • Once the gift is purchased, the responsible person changes the value of the metadata field and the business process ends.
    secret_santa3
  • If the gift isn’t purchased in five days, the giver gets reminded by email.secret_santa4

What’s going on behind the scenes

There are actually three separate Laserfiche Workflow business processes that run behind the scenes.

Workflow 1

This Laserfiche Workflow business process does the following:

  • Creates tokens that will be used to assign random gift givers to gift recipients. These tokens are used in the script later on in the workflow.
  • Finds all submissions without any giver assigned.
  • Uses a special Flag field to make sure that no one is assigned to purchase a gift for himself.
  • Generates a random number using an SDK Script. This number is used to match the recipient to the giver.
  • Populates the submission’s metadata fields with the name of the assigned giver.

Here is what the script looks like. The tokens “maxrandom” and “randomnumber” must be created first with the Create Tokens activity.

secret_santa5

Here is what the whole workflow looks like:

secret_santa6

Workflow 2

Once all of the givers are assigned, this Laserfiche Workflow business process iterates through each submission and launches the third workflow, described below.

secret_santa7

Workflow 3

This workflow is responsible for the various notifications. First, it routes the submission to a brand new folder and then assigns Browse, Read and Write Metadata rights to the submission for the giver. It also emails the link to the submission to the giver. If the giver doesn’t purchase a gift within five days, the workflow sends another email notification.

Here is what this workflow looks like:

secret_santa8

Some things to keep in mind

Here are some things to keep in mind when setting up this process:

  • Users participating in the Secret Santa exchange should have accounts in Laserfiche already or permissions configured through Windows groups. Laserfiche will assign the security to the folders it creates as necessary.
  • To make the process less confusing to the user, the two fields used by Laserfiche Workflow, Doc Assigned and Flag, can be hidden from everyone but the Workflow user. Since users can only edit one field, they will know exactly what action they have to perform.secret_santa9
Some of the products and services listed on the Laserfiche Solution Exchange were not developed by Laserfiche. The recommendations and opinions expressed on the Laserfiche Solution Exchange are those of the person or persons posting the recommendations only, and they do not necessarily represent Laserfiche's opinion or recommendation of the product or service being reviewed. Laserfiche disclaims all liability resulting from your purchase or use of any non-Laserfiche software product or service listed on the site.