Salesforce

Related Lists on Visual Force Pages

« Go Back
Article
Overview

This feature allows the user to manage the display of related lists on the Rootstock Visual Force (VF) pages. Eligible objects to be displayed are those that have a master-detail or lookup relationship with the primary object, which is the main object of the VF page where the related lists are to be displayed. The functionality supports packaged & custom objects, as well as primary object history's related list.

Processing
 
  1. Determine the Child Relationship Name of the child object lookup to the primary page object.

User-added image  NOTE  If the user wants to add the primary object history's related list, this step can be skipped. The Child Relationship Name is Histories.
 
  • Navigation: Salesforce Setup > Create > Objects.
  • Locate the object that you want to base the related list content on, and click on it.
  • Browse to and click on the Field Label link of the desired lookup field. This lookup field will be Related To the Primary Object from the VF page where we want to display the related list.
  • Locate the value of the Child Relationship Name field under lookup options.
  • Copy the Child Relationship Name, as this is the value that will be used to configure the related list for display on the Rootstock VF Pages.
User-added image  EXAMPLE  If the user is to add a related list to display the Inventory Location IDs for a given Site Master (related list on object Site Master VF page). The user would access the Inventory Location ID object on this step, look for the lookup field to Site Master (Primary Object), and click on the Site hyperlink (below). For this example, the Child Relationship Name needed is: SYLOCIDs

User-added image
 
  1. Add Child Relationship Name from step 1 to Menu record.
  • Navigation: System Setup > Site Map-Menu Bar.
  • Locate the Menu record for the Primary Object that the related list is to be added to. If there are more than one Menu records with the same Name/Primary Object Name, perform changes to that with an empty Menu Configuration field value.
  • Create the syntax with the Child Relationship Name value copied on step 1 as:
    • For Rootstock Managed Objects: rstk__ + Child Relationship Name + __r (both the prefix and suffix have two underscores)
    • For Custom Objects, the syntax would not include the prefix and simply be: Child Relationship Name + __r
    • For the Object History related list, the syntax is simply: Histories
  • Add above syntax to the field on Menu record: Related List Child Objects, save changes.
  • Go to the Primary Object VF page, the new related list should be displayed if the user has correct permissions.
  • The user can optionally add the Approval History section to display under the related list of the primary object's Visual Force page by checking the Approval Enabled checkbox.
  • The user can optionally add the Open Activities, Activity History sections to display under the related list of the primary object's Visual Force page by checking the Activities Enabled checkbox.
 
User-added image  NOTE  The field Related List Child Objects is not case sensitive. To add multiple related lists, either separate the entries by a comma or add each entry on a separate line. The related lists will be displayed in the sequence of these entries.
 
User-added image  EXAMPLE  On step 1. we located the lookup to Site Master on Inventory Location ID was, with a Child Relationship Name: SYLOCIDs. This step consists of adding rstk__sylocids__r to the field Related List Child Objects on the Menu record.
 
  1. Configure displayed fields for the related list added on step 2 by editing page layout of the Primary Object on Menu record.
  • Navigation: Salesforce Setup > Create > Objects
  • Select the Primary Object.
  • Navigate to the Page Layouts section and select Edit. 
  • Select Related Lists from the left-top menu column.
  • Look for the object of the related list to edit the fields display. If not already added to the Standard page display, add it.
  • On the lower section, search for the related list, and click the Tool icon.
  • A pop-up window with fields available will be displayed. Edit as desired, click OK, and Save layout changes.
     
User-added image  EXAMPLE  For the previous example, add the Inventory Location IDs to the Site Master VF page as a related list, below shows how to look for the Inventory Location ID related list while updating the Standard Salesforce Layout of the Site Master object.
 
User-added image
 
Settings
Related Lists on Visual Force Pages
Related-Lists-on-Visual-Force-Pages

Powered by