Workflow Configuration

Description

Every workflow configured for a package gets a chance to execute with every submission of that package.  Workflows consist of triggers and true/false actions.  Triggers determine the criteria for executing a workflow, true actions are taken when those criteria are met for a particular package submission and false actions are taken when those criteria are not met for a particular package.  The true and false actions are optional for each workflow configuration.

Initializing a New Workflow

The workflow configuration page for a new workflow will look like the picture above.  The workflow is automatically named "New Workflow" and you can change that name using the pencil icon.  The toolbar is laid out as follows:

  1. Trigger tab.  Here you will define the trigger that determines when this workflow executes.  This is shown in more detail below.
  2. True Action tab.  Here you define the action to take whenever the trigger criteria are met for a particular package submission.
  3. False Action tab.  Here you define the action to take whenever the trigger criteria are NOT met for a particular package submission.
  4. The trash icon will delete this workflow
  5. Press save whenever your workflow changes to store to the database


Trigger Configuration

Trigger configuration makes use of the string builder (see String Builder for more information.)  All triggers must be true in order for the True Action to execute.  By default, a workflow is initialized with a single trigger.  To configure, you can either use a field type of:

  1. Form Action - then choose one of the appropriate form actions.  Form actions are completely configured on the "Left" side
    1. ALWAYS - this form action always evaluates to true on every submission
    2. ON SUBMIT - this form action evaluates to true on a submission, but not on an approval or rejection if this form package is in an approval workflow
    3. ON APPROVE - this evaluates to true when a form package in an approval workflow is approved
    4. ON REJECT - this evaluates to true when a form package in an approval workflow is rejected
      This shows a trigger completely configured.  This means that the True Action will always be run when a package of this type is approved in an approval workflow

  2. Other string builder content.  If you are not using the Form Action here, you can construct a string using the String Builder functionality by following the linked article.  When using string builder content, it is necessary to compare the "Left" string builder content to the "Right" string builder content using the specified operator.  Note that some operators will only work for integer comparison and some will only work for string comparison.

    This shows a trigger completely configured using string builder comparisons.  Here you can see that for this expense report submission field "total" we are going to make an INT comparison to a static value of 1000.  If the "total" field content evaluates to greater than the value 1000, then the True Action will be taken.

    1. Left - Can be composed of any String Builder value
    2. Operator will be one of the following: 
      1. LessThen - Integer
      2. LessThanOrEqual - Integer
      3. Equal - Integer
      4. GreaterThenOrEqual - Integer
      5. GreaterThan - Integer
      6. Contains - String
      7. Equals - String
      8. StartsWith - String
      9. EndsWith - String
    3. Right - Can be composed of any String Builder value


Action Configuration

Now that you know how to engage one of the actions based on your trigger either evaluating true or false, it is time to see what actions are available.  Some of the more involved actions are described in their own article linked off of this page:

  1. Route to Usernum
    Description
    This triggers an approval routing workflow within the Forms inMotion system.  The submitted package will be sent to this user if the workflow trigger evaluates to true

    Parameters:
    1. To Address - this String Builder content should be the user number of a user in the system to which this form package should be routed
      1. Approval Required - turning this on will make the form require approval or rejection from the user it is routed to.
      2. Send Notification - turning this on will send a notification to the destination user that a package has been forwarded to them.
    2. Message - this String Builder content is the text message that will go along with the routed form package.  This might include instructions for the recipient, etc.
  2. Route to User Email Address (Route to User ID in previous versions)
    Description
    Similar to #1 above, this triggers an approval routing workflow within the Forms inMotion system.  The submitted package will be sent to this user if the workflow trigger evaluates to true.  The difference here is that the routing occurs based on the users login email address instead of their system user number

    Parameters
    1. To Address - this String Builder content should be the user number of a user in the system to which this form package should be routed
      1. Approval Required - turning this on will make the form require approval or rejection from the user it is routed to.
      2. Send Notification - turning this on will send a notification to the destination user that a package has been forwarded to them.
    2. Message - this String Builder content is the text message that will go along with the routed form package.  This might include instructions for the recipient, etc.
  3. Write to Disk
    Description
    Only available in premise based solutions, this allows the writing of output directly to the disk.  

    Parameters
    1. Write to Folder - this String Builder content is the output folder in which your output will be written.  Note that this is always appended to the Output Root site property is configured under Settings for this particular installation
    2. Types of files to write - this File Builder content specifies exactly which files to write into the output location
  4. Send EMail
    Description
    This will send the configured message and attachments as an EMail.  This will only work if the smtpsever, smtpport, and smtpfrom at minimum are configured under Settings for this particular installation.  Documentation of the SMTP configuration can be found here Setting up SMTP.

    Parameters
    1. To - this String Builder value must be the valid to address.  Invalid emails will just fail to submit since the validity can't be checked until submission time.
    2. From - this String Builder optional parameter will override the Settings site property smtpfrom if configured
    3. Subject - this String Builder value will become the subject line for the email message
    4. Body - this String Builder value will become the body of the email message
    5. Types of files to write - this File Builder content will all become attachments to the email
  5. Upload to ShareBase
    Description
    Similar to writing files to disk, this will write them to your ShareBase instance.  Before starting this, create the ShareBase folder under which you wish to write files and get the folder id as shown here Configuring ShareBase integration

    Parameters
    1. Write to folder # - This String Builder value should be the folder ID for the ShareBase folder you already created
    2. ShareBase email address - This String Builder value is the email address of your ShareBase login
    3. ShareBase Password - this String Builder value is the password for your ShareBase login
    4. Types of files to write - this File Builder content will be uploaded to ShareBase
  6. Post to OnBase
    Description
    This allows uploading documents to the OnBase system directly through the Unity Integration Toolkit API.  This integration is described here OnBase Workflow Configuration
  7. Post to DocuWare
    Description 
    This allows uploading documents to a Docuware system directly through the API.  This integration is described here DocuWare API Workflow Configuration
  8. Route to UserGroup Num
    Description
    This works in the same way as Route to a user, but this routes to an entire user group by group number

    Parameters
    1. To UserGroup Address - This String Builder value should be a valid Forms inMotion usergroup number
      1. Approval Required - turning this on will make the form require approval or rejection from the user it is routed to.
      2. Send Notification - turning this on will send a notification to the destination user that a package has been forwarded to them.
    2. Message - this String Builder value should be the message to include with the routed form package
  9. Route to UserGroup Name
    Description
    This works in the same way as Route to a user, but this routes to an entire user group by group name

    Parameters
    1. To UserGroup Address - This String Builder value should be a valid Forms inMotion usergroup name
    2. Message - this String Builder value should be the message to include with the routed form package
  10. Write to (S) FTP
    Description
    This will connect to an FTP or SFTP server and upload the specified content

    Parameters
    1. FTP Server - this String Builder value is the FTP server to which we will connect
    2. FTP Port - this String Builder value is the FTP port to which we will connect
    3. FTP User - this String Builder value is the FTP user with which we will login
    4. FTP Password - this String Builder value is the FTP password with which we will login
    5. SFTP Host Fingerprint - this String Builder value is the used for secure communication with an SFTP server.  You must use a 3rd party tool such as WINSCP to get this value.  The process is described here Write to (S)FTP.
    6. FTP Folder - this String Builder value is the FTP output folder
    7. Types of files to write - this File Builder content describes which files to write to the FTP Server
  11. Post Submit Behavior
    Description
    Post submit behavior is the only CLIENT SIDE workflow behavior.  This allows you to force the client to either show a message or redirect the user to a URL based on a workflow trigger.

    Parameters
    1. Redirect URL - This String Builder value is the URL to which the client should be sent after this workflow evaluates true
    2. HTML Message Text - this String Builder value is a string of valid HTML that will be shown to the client upon this workflow trigger evaluating to true