Approval processes are a type of automation that allows users to submit Salesforce records so that they can be approved in order to continue a specific business process. The approval process has the option of sending the record to one or multiple approvers (in a round-robin fashion), as well as the ability to add submission, approval, rejection, and recall actions. Having these checks and balances on business processes allows for a more streamlined and efficient workflow. Creating and maintaining approvals is a vital part of a Salesforce admin’s day-to-day work.
In this chapter, we will cover the following topics in detail:
With the help of these topics, you will understand when and how to create an approval process. You will understand how to create an approval process, add entry criteria, select approver(s), add actions, and add approval steps. These skills will help you automate business processes for your organization, leading to higher efficiency and fewer errors being made by your users.
For this chapter, log into your development organization and follow along as we create an approval process from start to finish.
An approval process is a great tool that’s used to execute business logic automatically based on a Salesforce record being submitted for approval, and then approved or rejected by another user. Knowing the capabilities of approval processes will help you come up with efficient workflows that lead to fewer clicks and cleaner data. Let’s see how this is done.
You are the Salesforce Admin for XYZ Widgets. The sales manager has a use case where all closed sales that are $200,000 or higher and are in the negotiation/review stage need to be submitted to them for final approval. Once the deal is approved, the opportunity stage should automatically update to Closed Won. Let’s build this approval!
To create the approval process, perform the following steps:
Figure 17.1: Navigating to Approval Processes from the Home tab
Figure 17.2: Navigating to the Jump Start Wizard for an approval process
There are two steps you need to follow in order to start creating the approval process, as shown in the preceding screenshot:
The next page we will be taken to is the Jump Start Wizard. Now, let’s take a look at the Wizard and see how we can add entry criteria and approver selection.
Now, we need to add the basic approval process information, specify the entry criteria for the approval, and select the approver(s) for the approval process. Refer to the following screenshot for more details:
Figure 17.3: Important areas for adding basic approval process information
From the preceding screenshot, you can see there are four main sections, each of which has specific settings for the approval process. Let’s look at these settings in detail:
$200,000
After saving, we will see the following screen:
Figure 17.4: Setup page listing actions to add to an approval process
As you can see, the preceding screenshot suggests that we finish setting up this approval by adding additional actions. Let’s click on View Approval Process Detail Page to proceed.
Now, we can start adding actions and viewing the approval steps.
Now that we have created the approval process, let’s look at how to add actions and view the approval steps based on our business use case. The following screenshot shows where we land after clicking on View Approval Process Detail Page:
Figure 17.5: Highlighted areas of the Approval Process Detail Page
As shown in the preceding screenshot, there are multiple sections to consider:
Now, let’s look at Final Approval Actions:
Figure 17.6: Dropdown options for Final Approval Actions
For Final Approval Actions, we need to add one action. Since our business use case says we want the opportunity stage to automatically update to Closed Won when the record is approved, we will need to add a field update. From the Add New dropdown, select Field Update, which will take us to the following screen:
Figure 17.7: Screen for editing a field update
After adding the required information here for the field update, save it. This has been set up so that when the approver approves the record, this field update will occur and the opportunity stage will automatically change to Closed Won. After doing this, we will be sent back to the following screen:
Figure 17.8: Returning to the screen for adding actions to an approval process
As shown in the preceding screenshot, there are two more sections to cover on this page:
For our business use case, there are no additional actions needed for a rejection, so we will leave this as is.
Now that we have added the actions needed for this approval process, we need to activate the approval by clicking Activate:
Figure 17.9: Button for activating an approval process at the top right of the screen
Although the approver(s) will get a notification and can approve the record right from inside Salesforce, we want to add an extra option to make it a little easier for our executives on the move. This option is to allow the approver to approve a record by replying to the approval request email with APPROVE
or REJECT
.
In the following screenshot, I navigated to Process Automation Settings to enable this feature:
Figure 17.10: Navigating to Process Automation Settings from the Home tab
As you can see, I ticked the Enable email approval response checkbox. This will now give our approver(s) another option to approve the record:
Figure 17.11: Example of an approval response email
Now that we have set up the approval process and enabled the option for an approver to approve via email, let’s test it out!
Now that we have built the approval process, let’s test it out to see if it meets our business requirements. As a recap, the sales manager wants all closed sales that are $200,000 or higher and are in the negotiation/review stage to be submitted to them for final approval. Once the deal has been approved, the opportunity stage should automatically update to Closed Won. Let’s see how this works:
Figure 17.12: Opportunity with the amount and stage sections highlighted
Here, we can see that this opportunity has an amount that is greater than $200,000 and is in the Negotiation/Review stage, so it meets the criteria for being submitted for approval.
Figure 17.13: Popup when submitting an approval above a certain amount
The opportunity has now been submitted. The following screenshot shows the list related to the Approval History of the opportunity:
Figure 17.14: Highlighted entries in the Approval History section
Figure 17.15: Items to Approve section on the approver’s home screen
As you can see, the sales manager would have to log into Salesforce.
Figure 17.16: Approve button found on the sales manager’s screen for a record
In the preceding screenshot, you can see all of the approval details. The sales manager has the option to Approve, Reject, or Reassign the record for approval.
Figure 17.17: Popup when clicking on Approve
This popup allows the approver to add any comments to the approval. The sales manager will click on Approve and be brought to the following screen:
Figure 17.18: Opportunity with approval status highlighted
From the preceding screenshot, we can see that the opportunity has been approved (1).
Figure 17.19: Opportunity stage after an opportunity is approved
The opportunity automatically changed to Closed Won when it was approved by the sales manager.
Figure 17.20: Approval status displayed in the Approval History section
As you can see, Step 1 has now changed from Pending to Approved.
Now that we have tested the business use case successfully, let’s go over what we have learned in this chapter.
In this chapter, we learned what approval processes are and the use cases for building approvals into our business processes. We learned how to create an approval process and define the entry criteria and select an approver. We also learned how to view approval steps, as well as add various actions based on submitting, approving, rejecting, and recalling the record.
With the use of these skills, you should be able to come up with checks and balances that control various aspects of the business process flow, as well as apply technical solutions for the approval-related requirements that come from your users. In the next chapter, we will look at a different automation tool available in Salesforce, assignment rules.
Join our community’s Discord space for discussions with the authors and other readers: https://packt.link/rlptF