FX Form Setup

Prerequisites

Guidelines

Master-Detail Field

  • The Master-Detail field controls the parent object for an FX Form and determines the type of record for which you can add the FX Form.

    If an FX Form has a master-detail relationship with the Ticket object, you can add the FX Form to tickets.

  • You must add a Master-Detail field to every FX Form.

SyncId Field

  • The SyncId field controls whether an FX Form syncs to FieldFX Mobile.

    FX Forms only sync if they have a unique value set in the SyncId field.

  • To prevent sync issues, you must:

    • Add a SyncId field to every FX Form.

    • Add a workflow rule to assign unique sync ids to FX Forms automatically.

Adding an FX Form

Customers should review the terms and conditions of the Software Subscription and Support Agreement with LiquidFrameworks (including the SFDC Supplemental Terms) to understand the rights and restrictions that Customers have regarding creating custom objects.

  1. Access FieldFX Back Office

  2. Switch to Salesforce Classic

  3. Add a custom object for the FX Form:

    1. From Setup, enter "schema" in the Quick Find box, then select Schema Builder

    2. Click the Elements tab

    3. Drag Object from the Elements panel onto the grid

      Screenshot of dragging an object to the Elements panel
    4. Complete the following:

      1. In Label, enter a name for the FX Form

        JSA

      2. In Plural Label, enter a plural name for the FX Form.

        JSAs

      3. In Starts With, select "Consonant" or "Vowel"

      4. In Data Type, select "Text"

      5. Select Allow Reports

      6. Select Add Google Docs, Notes, Attachments, related list to default page layout

    5. Click Save

  4. Add the Master-Detail field:

    You must add a Master-Detail field to every FX Form.

    1. Drag Master-Detail from the Elements panel onto the FX Form object

    2. In Field Label, enter:

    3. In Related To, select:

    4. Click Save

  5. Add the SyncId field:

    You must add a SyncId field to every FX Form.

    1. Drag Text from the Elements panel onto the FX Form object

    2. In Field Label and Field Name, enter "SyncId"

      The Field Label and Field Name fields are case-sensitive, so you must enter SyncId correctly.

    3. In Length, enter "50"

    4. Select Unique

    5. Under Is Case Sensitive, select Treat "ABC" and "abc" as duplicate values (case-insensitive)

    6. Select External ID

    7. Click Save

  6. Add fields to collect data:

    1. Drag a field type from the Elements panel onto the FX Form object

    2. Enter field attributes

      Don’t give a custom field the same name as a field on a FieldFX object.

    3. Click Save

    4. Repeat steps a to c as needed

  7. Define the layout:

    1. Click the gear icon on the FX Form object and select View Page Layouts

      Screenshot of selecting the View Page Layouts option
    2. Under Page Layouts, click Edit next to the default page layout

    3. Drag fields onto the page layout to create the FX Form

    4. On the toolbar, click Related Lists

    5. Drag Notes & Attachments into the Related Lists section

    6. Click Save

  8. Add an FX Form configuration:

    1. Open the eForm Configs tab

    2. Click New

    3. In Key SObject, select:

    4. In eForm SObject, enter the API name of the FX Form object

      Example 1. Example API name to enter

      JSA__c

      The sObject name must be the object’s API name, which is case-sensitive.

    5. Specify when to use the FX Form

      If you don’t select one of the following options, users can add the FX Form to any job or ticket.

      1. In Key SObject Record Type, select a record type to use the FX Form for that record type

      2. In Account, select a customer to use the FX Form for that customer

      3. In Office, select an office to use the FX Form for that office

      4. In Segment, select a business segment to use the FX Form for that segment

      5. In Price Book, select a price book to use the FX Form for jobs/tickets linked to that price book

    6. In Sequence Number, enter a sequence number to use for the FX Form

      Sequence numbers control the order of FX Forms in lists. Refer to the Sequence Numbers article for more information.

    7. Click Save

  9. Add a Related List to page layouts:

    1. From Setup, enter "object" in the Quick Find box, then select Objects

    2. Complete one of the following:

    3. Under Page Layouts, click Edit next to a page layout for FieldFX Back Office

    4. On the toolbar, click Related Lists

    5. Drag the FX Form into the Related Lists section

    6. Click Save

    7. Click Yes

    8. Repeat steps c to g for other page layouts as needed

  10. Complete one of the following:

  11. Add a report template for the report version of the FX Form:

    1. Move back to FieldFX Back Office

    2. Open the Report Templates tab

    3. Click New

    4. In Report Template Name, enter a name for the report template

    5. In SObject, enter the API name of the FX Form object

    6. Click Save

    7. Click Attach File

    8. Click Choose File

    9. Select the report you defined for the FX Form

    10. Click Attach File

    11. Click Done

  12. Add a Visualforce page for the report version of the FX Form:

    1. From Setup, enter "pages" in the Quick Find box, then select Visualforce Pages

    2. Click New

    3. In Label, enter the name of the FX Form

    4. In Name, enter the name of the FX Form with underscores for spaces

    5. Copy the following code:

      <apex:page standardController="ObjectName" extensions="FX5.ReportTemplateExtension">
        <apex:includeScript value="{!$Resource.FX5__jquery1102minjs}"/>
        <style type="text/css">
          div.apexp {
            margin-left:-10px;
          }
          body {
            margin-left:0px !important;
          }
          a {
            text-decoration:none;
          }
        </style>
        <script type="text/javascript">
          $('td.labelCol.empty').remove();
          $('td.dataCol.empty').css('width','50%');
          $('td.labelCol.first').css('vertical-align', 'bottom');
          $('td.dataCol.first').css('vertical-align', 'bottom');
          $('input[type=submit]').appendTo('td.dataCol.empty');
          function jsOpenReport(entityId, templateId, objectTypeId, namespace)
          {
            var pagePath ='apex';
            var ctrl = document.querySelectorAll("[id$='reportPagePath']")[0];
            var customUrl='';
            if(ctrl!=null)
            {
              pagePath = ctrl.innerText;
              if(pagePath && pagePath.toLowerCase()!='apex')
              {
                customUrl='&customUrl=' + pagePath;
              }
            }
            var href = '/' + pagePath + '/' + namespace + 'Reporting?templateId='+ templateId + '&objectId=' + entityId + '&objectType=' + objectTypeId + customUrl;
            window.open(href, '_blank');
            window.top.location=window.top.location;
          }
        </script>
        <div style="display:none;">
          <apex:outputText id="reportPagePath" value="{!PagePath}" />
        </div>
        <apex:dynamicComponent componentValue="{!form}" id="dynamic"/>
      </apex:page>
    6. Replace the code on the Visualforce Markup tab by pasting over it with the code you copied

    7. In the first line of the code, replace "ObjectName" with the API name of the FX Form object

      <apex:page standardController="JSA__c" extensions="FX5.ReportTemplateExtension">
    8. Click the Version Settings tab

    9. Click -- Select to Add Installed Package -- and select "FieldFX Base Package"

    10. Click Save

  13. Update page layouts:

    1. From Setup, enter "object" in the Quick Find box, then select Objects

    2. Open the FX Form object.

    3. Under Page Layouts, click Edit next to a page layout for FieldFX Back Office

    4. On the toolbar, click Visualforce Pages

    5. Drag Section from the toolbar to a suitable location on the layout

    6. In Section Name, enter "Reports"

    7. Under Layout, select 1-Column

    8. Click OK

    9. Drag the Visualforce page for the FX Form report into the Reports section

    10. Click Save on the toolbar

    11. Repeat steps c to j for other page layouts as needed

  14. Add a workflow rule so that FX Forms sync to FieldFX Mobile:

    1. From Setup, enter "workflow rules" in the Quick Find box, then select Workflow Rules.

    2. Click New Rule

    3. In Object, select the FX Form object

    4. Click Next

    5. Complete the following:

      1. In Rule Name, enter "Sync Id Assignment".

      2. In Evaluate the rule when a record is, select created.

      3. In Run this rule if the following, select "formula evaluates to true".

      4. Enter the following formula:

        ISBLANK (SyncId__c)
    6. Click Save & Next

    7. Click Add Workflow ActionNew Field Update

    8. Complete the following:

      1. In Name, enter "Sync Id"

      2. In Field to Update, select "SyncId"

      3. In Text Options, select Use a formula to set the new value

      4. Enter the following formula:

        CASESAFEID(Id)
    9. Click Save

    10. Click Done

    11. Click Activate

  15. Grant permission to use the FX Form:

    1. From Setup, enter "permission" in the Quick Find box, then select Permission Sets

    2. Open a permission set

    3. Under Apps, click Object Settings

    4. Open the FX Form object

    5. Click Edit

    6. Under Record Type Assignments, select the record types for which to grant access

    7. Under Object Permissions, select Read, Create, and Edit

      If you didn’t select Unique when adding the SyncId field to the FX Form, grant View All permission for the FX Form object.

    8. Under Field Permissions, grant Read and Edit permission for every field

    9. Click Save

    10. At the top of the page, click the arrow next to Object Settings and select Visualforce Page Access

    11. Click Edit

    12. Add the Visualforce page for the FX Form to Enabled Visualforce Pages

    13. Click Save

    14. Repeat steps a to m for other permission sets as needed

  16. Configure sharing settings to grant access to the FX Form

  17. Add inline help for fields on the FX Form

Child FX Forms

Basics

Set up child FX Forms to record information related to another FX Form.

Example 2. Wireline logging tickets

If an FX Form records details for wireline logging tickets, add a child FX Form to record the measurements made during each logging run.

Child FX Forms have a master-detail relationship with a parent FX Form.

Adding a Child FX Form

Customers should review the terms and conditions of the Software Subscription and Support Agreement with LiquidFrameworks (including the SFDC Supplemental Terms) to understand the rights and restrictions that Customers have regarding creating custom objects.

  1. Access FieldFX Back Office

  2. Switch to Salesforce Classic

  3. Add a custom object for the child FX Form:

    1. From Setup, enter "schema" in the Quick Find box, then select Schema Builder

    2. Click the Elements tab

    3. Drag Object from the Elements panel onto the grid

      Screenshot of dragging an object onto the grid from the Elements panel
    4. Complete the following:

      1. In Label, enter a name for the child FX Form

        Logging Run

      2. In Plural Label, enter a plural name for the child FX Form

        Logging Runs

      3. In Starts With, select "Consonant" or "Vowel"

      4. In Data Type, select "Text"

      5. Select Allow Reports

      6. Select Add Google Docs, Notes, Attachments, related list to default page layout

    5. Click Save

  4. Add the Master-Detail field:

    You must add a Master-Detail field to every child FX Form.

    1. Drag Master-Detail from the Elements panel onto the child FX Form object

    2. In Field Label, enter:

    3. In Related To, select:

    4. Click Save

  5. Add the SyncId field:

    You must add a SyncId field to every child FX Form.

    1. Drag Text from the Elements panel onto the child FX Form object

    2. In Field Label and Field Name, enter "SyncId"

      The Field Label and Field Name fields are case sensitive so you must enter SyncId correctly.

    3. In Length, enter "50"

    4. Select Unique

    5. Under Is Case Sensitive, select Treat "ABC" and "abc" as duplicate values (case insensitive)

    6. Select External ID

    7. Click Save

  6. Add fields to collect data:

    1. Drag a field type from the Elements panel onto the child FX Form object

    2. Enter field attributes

    3. Click Save

    4. Repeat steps a to c for other fields

  7. Define the layout:

    1. Click the gear icon on the child FX Form object and select View Page Layouts

    2. Under Page Layouts, click Edit next to the default page layout

    3. Drag fields onto the page layout to create the child FX Form

    4. On the toolbar, click Related Lists

    5. Drag Notes & Attachments into the Related Lists section

    6. Click Save

  8. Add a Related List to page layouts:

    1. From Setup, enter "object" in the Quick Find box, then select Objects

    2. Complete one of the following:

    3. Under Page Layouts, click Edit next to a page layout for FieldFX Back Office

    4. On the toolbar, click Related Lists

    5. Drag the FX Form into the Related Lists section

    6. Click Save

    7. Click Yes

    8. Repeat steps c to g for other page layouts as needed

  9. Complete one of the following:

  10. Add a report template for the report version of the child FX Form:

    1. Move back to FieldFX Back Office

    2. Open the Report Templates tab

    3. Click New

    4. In Report Template Name, enter a name for the report template

    5. In SObject, enter the API name of the child FX Form object

    6. Click Save

    7. Click Attach File

    8. Click Choose File

    9. Select the report you defined for the child FX Form

    10. Click Attach File

    11. Click Done

  11. Add a Visualforce page for the report version of the child FX Form:

    1. From Setup, enter "pages" in the Quick Find box, then select Visualforce Pages

    2. Click New

    3. In Label, enter the name of the child FX Form

    4. In Name, enter the name of the child FX Form with underscores for spaces

    5. Copy the following code:

      <apex:page standardController="ObjectName" extensions="FX5.ReportTemplateExtension">
        <apex:includeScript value="{!$Resource.FX5__jquery1102minjs}"/>
        <style type="text/css">
          div.apexp {
            margin-left:-10px;
          }
          body {
            margin-left:0px !important;
          }
          a {
            text-decoration:none;
          }
        </style>
        <script type="text/javascript">
          $('td.labelCol.empty').remove();
          $('td.dataCol.empty').css('width','50%');
          $('td.labelCol.first').css('vertical-align', 'bottom');
          $('td.dataCol.first').css('vertical-align', 'bottom');
          $('input[type=submit]').appendTo('td.dataCol.empty');
          function jsOpenReport(entityId, templateId, objectTypeId, namespace)
          {
            var pagePath ='apex';
            var ctrl = document.querySelectorAll("[id$='reportPagePath']")[0];
            var customUrl='';
            if(ctrl!=null)
            {
              pagePath = ctrl.innerText;
              if(pagePath && pagePath.toLowerCase()!='apex')
              {
                customUrl='&customUrl=' + pagePath;
              }
            }
            var href = '/' + pagePath + '/' + namespace + 'Reporting?templateId='+ templateId + '&objectId=' + entityId + '&objectType=' + objectTypeId + customUrl;
            window.open(href, '_blank');
            window.top.location=window.top.location;
          }
        </script>
        <div style="display:none;">
          <apex:outputText id="reportPagePath" value="{!PagePath}" />
        </div>
        <apex:dynamicComponent componentValue="{!form}" id="dynamic"/>
      </apex:page>
    6. Replace the code on the Visualforce Markup tab by pasting over it with the code you copied

    7. In the first line of the code, replace "ObjectName" with the API name of the child FX Form object

      <apex:page standardController="Logging_Run__c" extensions="FX5.ReportTemplateExtension">
    8. Click the Version Settings tab

    9. Click -- Select to Add Installed Package -- and select "FieldFX Base Package"

    10. Click Save

  12. Update page layouts:

    1. From Setup, enter "object" in the Quick Find box, then select Objects

    2. Open the FX Form object

    3. Under Page Layouts, click Edit next to a page layout for FieldFX Back Office

    4. On the toolbar, click Visualforce Pages

    5. Drag Section from the toolbar to a suitable location on the layout

    6. In Section Name, enter "Reports"

    7. Under Layout, select 1-Column

    8. Click OK

    9. Drag the Visualforce page for the FX Form report into the Reports section

    10. Click Save on the toolbar

    11. Repeat steps c to j for other page layouts as needed

  13. Add a workflow rule so that FX Forms sync to FieldFX Mobile:

    1. From Setup, enter "workflow rules" in the Quick Find box, then select Workflow Rules

    2. Click New Rule

    3. In Object, select the child FX Form object

    4. Click Next

    5. Complete the following:

      1. In Rule Name, enter "Sync Id Assignment"

      2. In Evaluate the rule when a record is, select created

      3. In Run this rule if the following, select "formula evaluates to true"

      4. Enter the following formula

        ISBLANK (SyncId__c)
    6. Click Save & Next

    7. Click Add Workflow ActionNew Field Update

    8. Complete the following:

      1. In Name, enter "Sync Id"

      2. In Field to Update, select "SyncId"

      3. In Text Options, select Use a formula to set the new value

      4. Enter the following formula:

        CASESAFEID(Id)
    9. Click Save

    10. Click Done

    11. Click Activate

  14. Grant permission to use the child FX Form:

    1. From Setup, enter "permission" in the Quick Find box, then select Permission Sets

    2. Open a permission set

    3. Under Apps, click Object Settings

    4. Open the child FX Form object

    5. Click Edit

    6. Under Record Type Assignments, select the record types for which to grant access

    7. Under Object Permissions, select Read, Create, and Edit

    8. Under Field Permissions, grant Read and Edit permission for every field

    9. Click Save

    10. At the top of the page, click the arrow next to Object Settings and select Visualforce Page Access

    11. Click Edit

    12. Add the Visualforce page for the FX Form to Enabled Visualforce Pages

    13. Click Save

    14. Repeat steps a to m for other permission sets as needed

  15. Configure sharing settings to grant access to the child FX Form

  16. Add inline help for fields on the child FX Form

FX Form Configurations

Basics

An FX Form configuration controls when an FX Form is available for use.

You must add an FX Form configuration for every basic FX Form.

Child RX Forms use the FX Form configuration for their parent FX Form.

Adding an FX Form Configuration

  1. Access FieldFX Back Office

  2. Open the eForm Configs tab

  3. Click New

  4. In Key SObject, select:

  5. In eForm SObject, enter the API name of the FX Form object

    JSA__c

  6. Specify when to use the FX Form:

    If you don’t select one of the following options, users can add the FX Form to any job/ticket.

    1. In Key SObject Record Type, select a record type to use the FX Form for that record type

    2. In Account, select a customer to use the FX Form for that customer

    3. In Office, select an office to use the FX Form for that office.

    4. In Segment, select a business segment to use the FX Form for that segment

    5. In Price Book, select a price book to use the FX Form for jobs/tickets linked to that price book

  7. In Sequence Number, enter a sequence number to use for the FX Form

    Sequence numbers control the order of FX Forms in lists. Refer to the Sequence Numbers article for more information.

  8. Click Save

  9. Configure sharing settings to grant access to the FX Form configuration

Record Types

Basics

Set up record types if you need to complete FX Forms differently based on a certain aspect of a job.

Add Downstream, Midstream, and Upstream record types for an FX Form you complete differently at downstream, midstream, and upstream work sites.

Screenshot of different record types for an FX Form in FX Mobile

When you add record types, add a page layout for each record type. This allows you to display different fields on each version of the FX Form.

Adding Record Types for an FX Form

  1. Access FieldFX Back Office

  2. Switch to Salesforce Classic

  3. Add record types:

    1. From Setup, enter "object" in the Quick Find box, then select Objects

    2. Open the FX Form object

    3. Under Record Types, click New

    4. In Existing Record Type, select "--Master--"

    5. In Record Type Label, enter the record type

    6. Select Active

    7. Click Next

    8. Click Save & New

    9. Repeat steps d to h for other record types as needed

    10. Click Save to finish

    11. Click Back to Custom Object at the top of the page

  4. Add page layouts for each record type:

    Page layouts control the fields that display on each version of an FX Form.

    1. Under Page Layouts, click New

    2. In Page Layout Name, enter the record type

    3. Click Save

    4. Drag fields onto the page layout

    5. Click Save

    6. Repeat steps a to e for other page layouts as needed

  5. Assign the page layouts to record types:

    1. Under Record Types, click Page Layout Assignment

    2. Click Edit Assignment

    3. Click the column header for the record type

    4. In Page Layout To Use, select the record type’s page layout

    5. Repeat steps c and d for other record types as needed

    6. Click Save

  6. Grant permission to use the record types:

    1. From Setup, enter "permission" in the Quick Find box, then select Permission Sets

    2. Open a permission set

    3. Under Apps, click Object Settings

    4. Open the FX Form object

    5. Click Edit

    6. Under Record Type Assignments, select the record types

    7. Click Save

    8. Repeat steps a to g for other permission sets as needed