Field Service Lightning (FSL) enables businesses to unite customers, connected devices, agents, dispatchers, and employees in the service field with one powerful service platform that delivers a seamless customer experience with field service.
Let us see how to implement this in Salesforce from scratch and step-by-step process from Service creation to completion.
To implement the FLS, two managed packages need to be installed:
- Base Package
It contains object data model.
- Lightning Package
It contains Field Service Lightning App
Installation of Base Package:
Before installing packages, we need to create custom profiles that need to be used in the installation step. Create three profiles FSL Admin, FSL Dispatcher and FSL Mobile by cloning the existing ‘Standard User’ profile. (Note: Only three standard profiles FSL Admin, FSL Dispatcher and FSL Mobile are available in FSL Package)
Link to install base package: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t200000002TPE
Installation of Lightning Package:
Link to install Lightning Package: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t240000002MGK
While installing, select for specific Profiles only and select three new profiles (as shown below) we created earlier and click ‘Yes’ to grant access to third party web sites.
[Text Wrapping Break]
Once installed successfully, assign the newly created profiles with appropriate page layouts (available after installation) for Account object.
Likewise, repeat the steps for other objects: Calendar, Location, Resource, Service and Service Type.
After creating necessary fields for necessary objects, create records as specified in below screenshots.
A location defines a working unit, department or district and group together employees and services. It may or may not have a geographical aspect.
Once the Parent Location is specified, the time zone is fetched from parent.
The Skill object is a catalogue of employee skills used to define what each employee can do, or what is required to perform a service.
Service Type Object:
It contains type of Service and duration of that particular service type.
Once created, embed the inbuilt VF page (skills) provided and select the appropriate skill check box and select the level based on the service type.
It is used for specifying the working hours of the resources. A resource can have more than one calendar, effective for different time ranges. Also, it is used for specifying the organization appointment booking windows.
Resource is the one who will be assigned to a specific service to complete it based on resource skill and availability of resource calendar. Address details will be used from the user record of salesforce.
By selecting the Skill checkbox in the VF page (in built), associated records will be added to the Resource Skills related list as below for Resource ‘Alan Reed. A calendar also need to be associated for this resource.
Service details can be seen through Gantt in ‘Field Service’ tab. Everything can be tracked from here: Resource, Location, and Service assigned to resource.
Scheduling Policies, Work Rules, and Service Objectives:
Field Service Lightning comes with a predefined set of scheduling policies, work rules, and you can edit them or create your own.
A work rule places a constraint on scheduling. It defines which assignments (an assigned resource, such as a technician, for a specific service at a specific time) are valid and which are not.
A Service Objective reflects a scheduling goal or target. Each objective returns a grade, or score, for services. When a service is scheduled, the scheduling engine calculates the added score of an objective, and the total score of all objectives taken into consideration in the scheduled service’s total score. Services with higher scores are preferred by the scheduling engine.
A scheduling policy is a set of work rules and service objectives that the scheduling engine can consider when it’s finding the best candidates and slots to create an optimized schedule
Predefined set of above mentioned are available by default and below is the one where you can create new policy and assign it for your process.
Create a new Scheduling Policy using Scheduling Policies tab and associate relevant work rule and service objectives. Once created, go to ‘’Field Service Settings’ tab under Field Service Admin’ app.
‘OAE Standard policy’ (blurred below) is the newly created Scheduling policy and it is set as default scheduling policy.
Appointment Booking and Service Levels:
Appointment booking can be done in any standard or custom object through quick action ‘Book Appointment’ which is predefined and we can set for which object we need to book using ‘Booking Preferences’ section of ‘Appointment Booking’.
Based on the default preferences provided in above screenshot, it will display resource by checking location, skill and slots available while booking appointment as below.
If you select any specific time, a Service will be created.
The Emergency Service action is to schedule, dispatch, and track emergency appointment in just few clicks of a real time map view.
Resource location is calculated based on resource’s Current Location and Customer data.
Click on ‘Dispatch’ (blue) button. Then, click on ‘Confirm & Dispatch’.
A new Emergency Service will be created.
The Contractor is an external resource, if we enable the contractor checkbox.
On the same details page, we must set the Contractor Capacity I.e. Working hours per day.
Contractor Logic & Relevance Group:
Add Service Objective under Scheduling Policies to set the Contractor grade/score.
Then, add Work Rule in Scheduling Policies for Contractors’ maximum travel distance from home.
Lightning App – Salesforce 1:
The Field Service Lightning is available in Salesforce1; so, field technicians can easily navigate to service location, change status, and more.
Create a new page from Lightning App Builder: Setup > Lightning App Builder.
Choose the Filter List component > select the list view under the Service object.
Save and Activate the App > then specify the App Name > order the App location.
Now, the Resource can log into the Salesforce1 and view the list of services. When viewing the service record, users can locate the service address on map. Resource can change the service status anytime. Once the status is changed, resource’s location is updated in the Map.
Process from Service Creation to Service Complete:
- Service will be created based on the manual creation or through ‘Book Appointment’ quick action. It will create a Service from quick actions on any standard or Custom Object provided if that is configured before using ‘Appointment Booking’ section under ‘Field Service Setting’ of ‘Field Service Admin’ by giving Specified Service Type.
- Based on Skill (Proficiency), Location (Address) and availability (Calendar), appropriate resource will be allocated to service. This resource allocation will be made by predefined/custom Scheduling policies, Work rules and Service objectives.
- Then, it will display available slot of the resource to perform the action, and once selected any service will be created and assigned to resource (Agent) with ‘Assigned’ status.
- Status Life Cycle can be framed according to the business
E.g. Assigned – Dispatched, Assigned – Rejected, Assigned-Accepted.
Dispatched – Travel –On Site (customer place) – Completed
Dispatched – Travel –On Site (customer place) – Incomplete
- Resource (Agent) can now access the service record through Salesforce1 once it is dispatched to resource.
- Resource can then update the status of work, and it will update on Service record.
- Resource can be viewed under map representation as below.