Workflow Step Conditional Logic introduces the ability to add conditional logic that changes the flow of a workflow based on the data in a workflow. Additionally, approval steps can be added and customized to your liking. Various actions are supported like stopping a workflow, going back and re-running a previous step(including the first step) or skipping to a future step.
Conditional Logic and Approvals are included as part of our Suite Teams plan. A conditional logic or approval step can be added after any step in a workflow. In this article we will be showing you how to setup your workflow with conditional logic and approval steps as well as going over some of the capabilities of Workflows.
How to setup a Workflow with an Approval Step
How to setup a Workflow with Conditional Logic Step
Supported Field Types for Workflow Conditional Logic
Frequently Asked Questions
How to setup a Workflow with an Approval Step
For this example, we've created a PTO request form that will be configured to be sent out to the appropriate manager for approval. The first step after building your form and creating your workflow is going to be to add the Form Workflow step by dragging and dropping it from left to right or clicking on the plus sign in the middle to select the appropriate product step. The option to add an approval step will be greyed out until this step has been added.
Once you've added your Form step and have chosen the form you'd like to use for your workflow, you'll then have the option to add your Approval step.
After you've added your Approval step, there will be an option to configure it. If you're building a multi-step workflow, it's important to note that you'll want to place this after the steps that you'd like to have your Approver review.
On the configuration page, you'll have a few different options to consider when constructing your Approval step. Starting from the top down, the first option to take a look at is who you want to assign to complete the task of completing this workflow. For this example, we piped in the managers email that would be filled out on the Form for the PTO request by dragging and dropping the workflow data from the left to the right. We've also added a custom message at the bottom using values from our form to capture the employees name and the time they'd like to take off.
Please note - It's possible to add as many approvers as you'd like to this section and you have the option to toggle on if you'd like all assignees to approve this step before the workflow proceeds or if any of the assignees can approve it and move the workflow forward. The approvers do not need to be Formstack users and we will give you an example below what the experience looks like for both types of approvers when we go over how to approve or reject a submission.
Scrolling down on the right to the next section, you have the ability to make adjustments to what happens when this step is approved and to configure a custom approval message if you'd like to give your approvers more information. When configuring what happens next if the step is approved, you have the option to Continue Workflow, Skip Ahead or Stop the Workflow altogether. If you choose the Skip ahead option and you have a multi-step workflow, you'll then see the steps you can skip. For this example, we chose to continue the workflow.
Scrolling down to the next section, you have the option to configure what happens when an approval step is rejected as well as the ability to include a custom message. When configuring what happens next if this step is rejected, you have the option to Stop Workflow, Continue Workflow, Go back to a step or Skip ahead.
For this example, we want to go back to a step if the manager has rejected the PTO request. When you select the Go back to a step option, you'll need to select which step you want to go back to and who you'd like to assign this step to.
In the form we built for this example, we included an email field for the employee and the manager and are able to drag and drop the employee email from the left to the right in the Assign to field to dynamically capture that info. You also have the option to pre-populate the form with the previously filled out information to save some time and you can choose to include a custom rejection message that can include any workflow data from the left.
Scrolling further down, the last option you'll want to take a look at on this page is the ability to add a custom identifier that your approvers would see when looking at these requests in their workspace. For this example, we've dragged and dropped our employee name from the workflow data on the left to help identify who each request is for.
After you've finished configuring your Approval step, you'll want to make sure to click the Done button on the top right to save your changes.
Now that your Approval step is configured, you'll want to decide on how you want to share this workflow by clicking on the share button on the top right. On the share screen, you'll have the option to copy and share the URL, get an embed code that you can use on your site or open the link on a new tab.
The next two examples will show you what you see as an approver for both Formstack Users and non-users alike. This is what an approver with access to Formstack would see on their end when viewing these submission from the workspace dashboard that can be accessed from the top when logging into Workflows. It's important to note that the workspace is only available to Formstack Users on your account, but you're still able to configure these steps for non-Formstack users if needed.
This is what an approver without Formstack access would see when they receive an email to approve or reject the submission.
How to setup a Workflow with Conditional Logic Steps
The first step to setting up a workflow with conditional logic steps is adding the steps you plan on using for your workflow. Otherwise, the option to add conditional logic steps will be greyed out until you add that information. For this example, we're creating an employee review workflow that will use conditional logic on our 2nd manager step to send back to the first step user based on how the second step is filled out. Below you'll see how we set this up with two separate steps that cover the employee and manager sections of the same Form, but you could also use seperate forms for the employee and manager to the same effect based on your own preference.
After you've added your Form steps, you'll want to make sure you're adding your step logic after the step that you'd like to reference for how you're setting up your logic. For this example, we want to reference how the manager will be filling out their portion of the form. Once you've added your Step Logic, go ahead and click on Configure Logic for the next step.
When configuring your workflow conditional logic, you can create a rule that's based on fields from your workflow step. When configuring your rule, you can select if this rule will follow all or any options and you can choose the conditional operator, whether it equals or contains a certain value as examples. You can also add as many rules as you'd like if you'd like to reference more than one field to determine what happens next with your Workflow. For this example, we've selected that if the value of our field equals Yes for Needing additional info, we want to then determine the next step of the Workflow. Check out our next step to see how we configured it.
When choosing what happens next with your Workflow step that contains conditional logic, you have a few different options. From stopping the workflow altogether, to skipping another step, to using our example and going back a step. When you choose the option to go back a step like our example below, you'll be presented with a few more options you need to fill out. You'll need to select the step you want to go back to and choose who you want to send it to as well as if you want to prepopulate the form step with the previously filled data and potentially include a custom message like we did below. In this example we piped over workflow data from the left hand side to dynamically include the email of the original employee filling out the form as well as including a custom message.
Please note - Whatever email you use to fill out a Formstack Forms step, does not require access to a Formstack user.
After you've finished making changes to your conditional logic step, please make sure to select the Done button on the top right corner.
Once you're ready to share this Workflow, you'll want to select the Share Workflow Button on the top right.
On this page you'll see the option to copy and paste your workflow URL, as well as the ability to get an embed code for adding to your own webpage or opening the URL on a new tab.
Frequently Asked Questions
What field types are supported when adding a conditional logic step?
Field types supported in conditional logic:
- Short-answer
- Long answer
- Name
- Address
- Phone number
- Date
- Dropdown
- Radio
- Checkbox
- Number
- Metadata (Submission ID, Submission Time, Browser, IP, Longitude, Latitude, Form ID)
Field types not supported in conditional logic condition are:
-
Time
- Payment fields
Can conditional logic be used to go back to an in-session Formstack Sign step?
Conditional logic action cannot be used to go back to an in-session Sign step.
Can I add a conditional logic step for Forms for Salesforce?
Forms for Salesforce steps are not supported in conditional logic at this time.
What happens to submissions when a form submitter has already completed their first step, but they potentially need to complete it again because of potentially being rejected or needing to add more information?
When going back to a previous Form step, the new submission will create a new submission record in Forms but we do not allow it to update the previously submitted record with the latest submitted data at this time.