Pulsar SFS Lightning Bolt Menu Customizations
The Pulsar SFS Lightning Bolt Menu can be customized to contain a subset of the elements that would normally appear in the Salesforce SFS Mobile Application.
Pulsar Setting:
pulsar.fsl.layout.{object type}.{optional record type developer name}.lightningbolt.listitems
How to Target Your Setting:
Let’s start by talking about the arguments to the above setting. The object and optional record type above are used to determine which Pulsar SFS pages will have the following customization applied to their lightning bolt menu.
Each page in Pulsar SFS has a single primary object context. You can see what the primary context of a given page is by clicking the Lightning Bolt Menu button and observing the header of the modal pop up. If the header shows both a Service Appointment and Work Order/Work Order Line Item, then it is a Service Appointment Context.
LBM in Pulsar 12.0 and prior | LBM in Pulsar 13.0+ |
Important: As shown above, the object context of pages opened from the calendar navigation displayed on the Schedule tab have ServiceAppointment as their primary object context. Referencing the WorkOrder or WorkOrderLineItem associated with this ServiceAppointment can be achieved through how the setting is written.
There is a special value for the object type, Global. This object context applies to many pages that do not derive their data from a specific object. The root page of each of the Pulsar SFS tabs has a Global context.
The Lightning Bolt Menu that can be optionally displayed on Global pages can be customized in exactly the same way with a few caveats. Use “Global” for object type and do not provide a record type. Additionally only Quick Actions from the Global layout will be available when filtering this list.
Pulsar 13.0 enhances the Lightning Bolt Menu but displaying the items in sections with icons similar to those seen in the Salesforce Field Service Mobile App. The 4 possible sections are:
Parent Object context items (e.g. Work Order)
Child Object content items (e.g. Service Appointment)
More Actions (those quick actions that are not scoped to any objects)
Global Actions (those items defined in
pulsar.fsl.layout.global.lightningbolt.listitems
)
How to Write Your Setting:
The value of this setting should be valid PSL (Pulsar Settings Language (PSL)) and should result in a SetResult PSL Action that sets the result value to a string in the expected format.
DEFAULT{
Action=SetVar;
VarName=AlternateFlowLabel;
VarValue="...";
|
Action=SetResult;
Result=parent : qa : WorkOrder.FSL__NewEvent
flow : Action_Test
default
custom : Asset Hierarchy : 0696A000005YLUL
flow : Mobile_Survey : %%AlternateFlowLabel%%
link : your_app_extension_name : useExternalBrowser
windows : https://www.microsoft.com : Microsoft Site
android : https://www.google.com : Google Site
iOS : https://www.apple.com : Apple Site
allPlatforms : https://www.luminixinc.com : Luminix Website
parent : windows : https://www.microsoft.com : Microsoft Site
parent : android : https://www.google.com : Google Site
parent : iOS : https://www.apple.com : Apple Site
parent : allPlatforms : https://www.luminixinc.com : Luminix Website
parent : flow : Test_Flow
parent : custom : Account Report : 069040000000pLRAAY : param1=value1¶m2=other+value+with%20spaces
}
Each row defines an entry or set of entries that we would like to have displayed in the lightning bolt menu for a particular object type. As mentioned above, these entries are limited to the set of entries that Salesforce considers accessible to a given object.
Pulsar 12.0 supports six entry types that are valid for the result string: default, qa, flow, parent, custom, link
default – The
default
option will insert all lightning bolt menu items that would appear normally had you not used this setting. This provides a way to modify the default list without reconstructing all the elements as well as use the default list as a fail safe in your PSL code. When used with other qa, flow, or parent entries you may have duplicate items in your resulting Lightning Bolt menu.qa – The
qa
option will insert a single quick action defined on the primary object context. The value following the colon is the quickActionName which determines the quick action that will be displayed. If the quick action is invalid for that context, no lightning bolt menu item will be displayed for this entry.flow – The
flow
option will insert a single flow defined on the primary object context. This behaves exactly as the qa option defined above. Flows are defined by the launchValue by placing it after a colon in the entry. The optional 3rd parameter, if defined, will be used as the menu item label value.parent – The
parent
option will insert a single quick action defined on the parent of the primary object context. The value following the colon in the entry determines if we want to display a quick action (qa
) or flow (flow
), or, in 13.0+, link (link, iOS, android, windows, or allplatforms - in 13.0+
) or custom document (custom
). The parent option simply precedes the normal syntax for the item type (see the example above). If the quick action is invalid for that parent context, no lightning bolt menu item will be displayed for this entry.parent_cc – The parent_cc option is similar to the parent option described above in that it places the action within the parent group, but it runs with the child object context. Currently, this option is only available for modifying custom actions.
custom – The
custom
option will insert a link to launch a custom document. The first value after the colon is the label you wish to display on the lightning bolt menu. The second value is the ContentDocument Id. Optionally, you may add URI query parameters as an additional item for any custom document (e.g.key=value¶m=text
). SeeAccount Report
in the example above. Document query parameters are available as of Pulsar 15.0.link – The
link
option will insert a link to launch a URI defined in Field Service Mobile Settings > App Extensions. The value after the colon is the App Extension Name you defined.
Pulsar 13.0+ supports an additional four entry types that can be used for web links or deep links: iOS, windows, android, allPlatforms
DEFAULT{
Action=SetResult;
Result=default
windows : https://www.microsoft.com : Microsoft Site
android : https://www.google.com : Google Site
iOS : https://www.apple.com : Apple Site
allPlatforms : https://www.luminixinc.com : Luminix Website
parent : windows : https://www.microsoft.com : Microsoft Site
parent : android : https://www.google.com : Google Site
parent : iOS : https://www.apple.com : Apple Site
parent : allPlatforms : https://www.luminixinc.com : Luminix Website
}
iOS – a web link or deep link that will only show on iOS devices.
windows – a web link or deep link that will only show on Android devices.
android – a web link or deep link that will only show on Windows devices.
allPlatforms – a web link or deep link that will show an all platform devices (iOS, Android and Windows).
Filtering based on screens:
This change allows the admin to set restrictions on where inside of the Pulsar app the particular lightning bolt menu items will appear. One of the following three options may be pre-pended to any of the lines in the PSL SetResult action:
all - this is the default screen context- It is equivalent to the behavior when not explicitly specifying a screen context. (The lightning bolt menu item will appear in both Pulsar object detail screens and on screens within Pulsar SFS)
record - This specifies that the lightning bolt menu item should only display on Pulsar object detail screens (or the “Global” lightning bolt menu, if applicable).
fsl - This specifies that the lightning bolt menu item should only display on screens inside of Pulsar SFS (Overview and Service Appointment schedule screen lightning bolt menus)
The following is a modification to the setting described above:
DEFAULT{
Action=SetVar;
VarName=AlternateFlowLabel;
VarValue="...";
|
Action=SetResult;
Result=fsl : parent : qa : WorkOrder.FSL__NewEvent
all : flow : Action_Test
fsl : default
custom : Asset Hierarchy : 0696A000005YLUL
flow : Mobile_Survey : %%AlternateFlowLabel%%
record : link : your_app_extension_name
}
This example, when scoped to a ServiceAppointment, has the following effects when the lightning bolt menu is opened:
“NewEvent” Quick Action will display ONLY in the lightning bolt menu within Pulsar SFS
“Action_Test” flow will display BOTH in the lightning bolt menu on the Pulsar ServiceAppointment detail page and within Pulsar SFS (specified explicitly here).
The “default” set of QuickActions and Flows will display starting after the “Action_Test” item ONLY on the lightning bolt menu within Pulsar SFS
“Asset Hierarchy” HTML item will display BOTH in the lightning bolt menu on the Pulsar ServiceAppointment detail page and within Pulsar SFS (default behavior- “all” is not explicitly specified)
“Mobile_Survey” Flow will display BOTH in the lightning bolt menu on the Pulsar ServiceAppointment detail page and within Pulsar SFS (default behavior- “all” is not explicitly specified)
The link specified in the app extension
your_app_extension_name
will appear ONLY in the lightning bolt menu on the Pulsar ServiceAppointment detail page.
Additional Settings
pulsar.fsl.lightningbolt.menuitems.enableSectionHeaderDetails
FALSE
by default. When set to TRUE
, the setting alters the appearance of the LBM to include object display names in the section headers, as well as making the LBM wider to accommodate longer display names.
pulsar.fsl.{ObjectType}.lightningbolt.menuitems.sectionOrder
The syntax is a list of sections, delimited by commas or newlines. The default value is:
parent, record, more, global
In this case record
refers to the context object type requested in the setting key. For example, for a ServiceAppointment (pulsar.fsl.serviceappointment.lightningbolt.menuitems.sectionOrder
) the different sections may correspond to the following:
parent
: The ServiceAppointment’s parent Work Order actions (if the parent of the ServiceAppointment is a WorkOrder object)
record
: The Service Appointment record’s actions
more
: The More Actions section (AppExtensions not scoped to either of the above objects)
global
: The Global Actions section
Any combination of these items in any order can exist in this setting, and sections may be omitted but may not be repeated.