Available in: Axsy Mobile for Salesforce, Axsy Field Service, Axsy Public Sector, Axsy Retail Execution



While making mapping changes described in this article, you must ensure your sync config related object tree supports the mappings you will implement in your Smart Form.


Considering the standard Field Service objects:

  1. Work Order
  2. Work Order Line Item
  3. Product Request

These objects all have a one to many relationship "cascade" which would be represented in a Salesforce page layout as related list items. I.e., Work Order Line Item is a related list item to Work Order and Product Request is a related list item to Work Order Line Item.


Figure 1 – One to Many Object Cascade



If we need to map content to and from both the Work Order Line Item object and the Product Request object in a single Smart Form Section, an example Smart Form that achieves this is shown in Figure 2.


Figure 2 – Smart Form Implementation



As both Repeating Sections and Loops support mappings, a Loop can be "nested" within a Repeating Section to facilitate two levels of mapping to be achieved. The Elements within area 1️⃣ in Figure 2 are subject to the mapping applied to the Repeating Section. The Elements within area 2️⃣ in Figure 2 are subject to the mapping applied to the Repeating Section and the Loop.


Figure 3 shows where levels 1️⃣ and 2️⃣ in the Smart Form correspond to the Salesforce object tree. Note level 0️⃣ is the object used to launch to Smart Form, but no mapping, in this example is applied.


Figure 3 – Corresponding Level Comparison between the Smart Form and the Object Tree



Mapping Configurations

Configuring Repeating Section Mappings

First we need to configure the mapping between the Work Order and Work Order Line Item objects. This takes place in the Mapping tab for the Repeating Section. See Figure 4 below, the Field Mapping (items and )can be populated using the magnifying glass lookup tool. Care should be taken to ensure the correct relationship name is used and this can be verified using Workbench. The Relationship Field name can be determined from Workbench, or can be found from Object Manager for the Work Order Line Item object and will always be either a Lookup or Master-Detail data type field.


Figure 4 – Configuring Section Mappings



Configuring Loop Mappings

Secondly we need to configure the mapping between the Work Order Line Item and Product Request objects. This takes place in the Mapping tab for the Loop. See Figure 5 below, the Field Mapping (items and )can be populated using the magnifying glass lookup tool. Care should be taken to ensure the correct relationship name is used and this can be verified using Workbench. The Relationship Field name can be determined from Workbench, or can be found from Object Manager for the Product Request object and will always be either a Lookup or Master-Detail data typ


Figure 5 – Configuring Loop Mappings



Element Mappings

With reference to Figure 2, any Element within area 1️⃣ is subject to the mapping path applied to the Repeating Section only, so we are mapping to fields in the Work Order Line Item object, to map to the Priority field the mapping will be constructed as shown in Figure 6. This can be put together using the magnifying glass lookup tool.


Figure 6 - Mapping for an Element inside the Repeating Section


Again with reference to Figure 2, any Element within area 2️⃣ is subject to the mapping path applied to the Repeating Section and the Loop, so we are mapping to the Product Request object. To map to the Status field the mapping will be constructed as shown in Figure 7. This can be put together using the magnifying glass lookup tool.

Figure 7 - Mapping for an Element inside the Repeating Section and the Loop