UIObjectRelationConfig

Represents the admin-created configuration of the object relation UI component.

Where possible, we changed noninclusive terms to align with our company value of Equality. We maintained certain terms to avoid any effect on customer implementations.

Important

Parent Type 

This type extends Metadata and inherits its fields.

File Suffix and Directory Location 

UIObjectRelationConfig components have the suffix .uiObjectRelationConfig and are stored in the uiObjectRelationConfigs folder.

Version 

Introduced in API version 54.0.

Special Access Rules 

You must be a Health Cloud or Life Sciences Cloud customer to use this metadata type

Fields 

contextObject 

  • Type: string

  • Required: Yes

  • Description: Required.

    The object that provides the context for this object relation configuration.

contextObjectRecordType 

  • Type: string
  • Required: No
  • Description: The record type of the context object for this configuration, if applicable.

directRelationshipField 

  • Type: string
  • Required: No
  • Description: For direct relationships, the child relationship field on the related object that matches the context object.

indirectObjectContextField 

  • Type: string
  • Required: No
  • Description: For indirect relationships, the field on the junction object that matches the context object.

indirectObjectRelatedField 

  • Type: string
  • Required: No
  • Description: For indirect relationships, the field on the junction object that matches the related object.

indirectRelationshipObject 

  • Type: string
  • Required: No
  • Description: For indirect relationships, the junction object representing the relationship between the related object and its context object.

isActive 

  • Type: boolean
  • Required: No
  • Description: Indicates whether the configuration is active (true) or not (false).

masterLabel 

  • Type: string

  • Required: Yes

  • Description: Required.

    Label for the UIObjectRelationConfig. In the UI, this field is UI Object Relation Config.

relatedObject 

  • Type: string

  • Required: Yes

  • Description: Required.

    The object containing the data that this object relation configuration displays.

relatedObjectRecordType 

  • Type: string
  • Required: No
  • Description: The record type of the related object for this configuration.

relationshipType 

  • Type: ObjectRelationshipType (enumeration of type string)

  • Required: Yes

  • Description: Required.

    A string indicating the type of relationship between the related object and context object.

  • Possible values:

    • Direct
    • Indirect
    • InverseDirect
    • Self

UIObjectRelationFieldConfigs 

  • Type: UIObjectRelationFieldConfig[]
  • Required: No
  • Description: Provides a configuration for an object relation field on a specific row of content.

UIObjectRelationFieldConfig Type 

Represents a configuration for a single row of content on a specific object relation configuration.

Fields 

displayLabel 

  • Type: string

  • Required: Yes

  • Description: Required.

    A string containing the user-defined label for this field, to be displayed on each object relation of this type.

queryText 

  • Type: string

  • Required: Yes

  • Description: Required.

    A case-insensitive template query for generating the content in this field.

rowOrder 

  • Type: int

  • Required: Yes

  • Description: Required.

    Determines the top-to-bottom display order of this field on the object relation UI.

Declarative Metadata Sample Definition 

This is an example of a UIObjectRelationConfig component.

1<?xml version="1.0" encoding="UTF-8"?>
2 <UIObjectRelationConfig xmlns="http://soap.sforce.com/2006/04/metadata">
3     <UIObjectRelationFieldConfigs>
4         <displayLabel>Address:</displayLabel>
5         <queryText>{
6     "startNode": {
7         "initialObject": "RelatedObject"
8     },
9     "traversalNodes": [],
10     "fieldNode": {
11         "fieldEnumOrId": "ShippingAddress"
12     }
13 }</queryText>
14         <rowOrder>1</rowOrder>
15     </UIObjectRelationFieldConfigs>
16     <UIObjectRelationFieldConfigs>
17         <displayLabel>Phone:</displayLabel>
18         <queryText>{
19     "startNode": {
20         "initialObject": "RelatedObject"
21     },
22     "traversalNodes": [],
23     "fieldNode": {
24         "fieldEnumOrId": "Phone"
25     }
26 }</queryText>
27         <rowOrder>2</rowOrder>
28     </UIObjectRelationFieldConfigs>
29     <UIObjectRelationFieldConfigs>
30         <displayLabel>Fax:</displayLabel>
31         <queryText>{
32     "startNode": {
33         "initialObject": "RelatedObject"
34     },
35     "traversalNodes": [],
36     "fieldNode": {
37         "fieldEnumOrId": "Fax"
38     }
39 }</queryText>
40         <rowOrder>3</rowOrder>
41     </UIObjectRelationFieldConfigs>
42     <UIObjectRelationFieldConfigs>
43         <displayLabel>Parent Organization:</displayLabel>
44         <queryText>{
45     "startNode": {
46         "initialObject": "RelatedObject"
47     },
48     "traversalNodes": [
49         {
50             "destinationObjectEnumOrId": "Account",
51             "fieldEnumOrId": "ParentId",
52             "traversalDirection": "parent"
53         }
54     ],
55     "fieldNode": {
56         "fieldEnumOrId": "Name"
57     }
58 }</queryText>
59         <rowOrder>4</rowOrder>
60     </UIObjectRelationFieldConfigs>
61     <contextObject>Contact</contextObject>
62     <directRelationshipField>AccountId</directRelationshipField>
63     <isActive>true</isActive>
64     <masterLabel>Sample Primary Account Configuration</masterLabel>
65     <relatedObject>Account</relatedObject>
66     <relationshipType>Direct</relationshipType>
67     <indirectObjectRelatedField></indirectObjectRelatedField>
68     <indirectObjectContextField></indirectObjectContextField>
69     <contextObjectRecordType></contextObjectRecordType>
70     <indirectRelationshipObject></indirectRelationshipObject>
71     <relatedObjectRecordType></relatedObjectRecordType>
72 </UIObjectRelationConfig>

This is an example package.xml that references the previous definition.

1<?xml version="1.0" encoding="UTF-8"?>
2<Package xmlns="http://soap.sforce.com/2006/04/metadata">
3  <types>
4      <members>*</members>
5      <name>UIObjectRelationConfig</name>
6  </types>
7    <version>54.0</version>
8</Package>

Wildcard Support in the Manifest File 

This metadata type supports the wildcard character * (asterisk) in the package.xml manifest file. For information about using the manifest file, see Deploying and Retrieving Metadata with the Zip File.