Note: This article explains how to customize related lists on Role record pages. To customize page layouts within the Roles component, see the Roles Component Admin Guide.
Use role categories--such as doctor, family member, or plaintiff--to customize page layouts for roles. Custom page layouts allow you to add fields and related lists tailored to each specific role, so you gather necessary information and store it with the role. To use custom page layouts, you must create record types for role categories. This guide will show you how to complete every necessary step.
Let’s say you’re adding an attorney role to a case and you want to gather information only necessary for attorneys, such as the attorney’s firm. Create a custom attorney layout to include the firm field. Selecting the Attorney category will open the customized page layout including the firm field.
Additionally, record types determine the related lists displayed in role summary. Edit the page layout assigned to a record type to change the related lists. You might need different related lists for Courts and Doctors, for example.
In this guide, we'll create a custom record type for the Court category.
Required setup: You must set up MDAPI access prior to completing this process.
To do this, first create a custom page layout for the role, then create a record type that references the page layout, then connect the category to the record type. Each step in this guide walks you through the process.
Create a Page Layout
Create a page layout for a specific role that you will connect to a record type in the next part of this guide. On this layout, we'll add the custom fields we need to display for the Court role category.
a. Navigate to Setup > Object Manager > Role > Page Layouts > New. Optionally clone an existing layout. Name the page layout, then click Save. This directs you to the page layout.
b. Add any custom or standard fields to the page layout. Select fields that are important for the particular role category. In this example, we're adding the Court Notes custom field to the page layout so users capture this information when adding Court roles to cases.
• Follow this guide to add related lists on roles.
Create a Record Type
Now that we have a new page layout, we need a record type that references this layout. This will be the record type for your role category.
1. Let's create a Legal record type that will use the page layout we created in the first part of this guide.
a. Navigate to Setup > Object Manager > Role > Record Types > New.
b. Name the new Record Type in the Record Type Label field. In this example, we're calling it the Legal record type. Then select profile availability. Certain intake agents might work on specific types of roles, so determine this access based on your firm's practices. Click Next.
c. On the Assign page layouts page, assign the custom layout you built to this record type.
Connect Role Category to RecordType
Use custom metadata to connect role categories to record types. This ensures that the role category you select pulls up your custom page layout when adding and viewing roles.
1. Navigate to Setup > Custom Metadata.
a. Click Role Category to RecordType.
b. Click Manage Role Category to RecordTypes.
c. Click New.
2. Set the Label and Name to something descriptive to keep them clear in your records.
3. In the Category field, type in the category you wish to be mapped. This is the category from step one. We're selecting the Court category.
4. For the RecordType Name field, type in the name of the record type you want to be mapped.
5. Click Save. When you go to create a new Role with the mapped category, the custom fields will now show up on the Role creation page in the Information section:
6. Additionally, related lists specific to the assigned page layout will display beneath Court roles.
Add Related Lists on Roles