Improving Clarity's Ticketing App with Root Objects

Complex object data models often include multiple related objects that need to share configurations, permissions, and lifecycle behaviors. For example, in Clarity's ticketing app, they plan to use three separate objects for tickets, attachments, and comments. This structure enables users to add multiple attachments and comments to a single ticket. While managing these separate objects manually would create overhead, Clarity can streamline this process by configuring root relationships.

In these exercises, you'll implement this data model for Clarity's ticketing app.

Exercise: Enabling the Feature Flag

Before you can use this feature, you must enable the Root Object Definitions (LPD-34594) feature flag for your instance.

  1. Open the Global Menu (Global Menu), go to the Control Panel tab, and click Instance Settings.

  2. Click Feature Flags.

  3. In the Release tab, search for LPD-34594 and enable it.

    In the Release tab, search for LPD-34594 and enable it.

With this feature flag enabled, you can start using the root object feature.

Exercise: Creating the Ticket Attachment Object

By creating a separate object definition for attachments, Clarity can capture metadata about each file (e.g., title, description) and relate as many attachments to a ticket as needed. Here you'll create and publish the Ticket Attachment object as the Clarity Admin user.

  1. Open the Global Menu (Global Menu), go to the Control Panel tab, and click Objects.

  2. Go to the Ticketing folder.

  3. Click View in Model Builder.

  4. Click Create New Object, enter these details, and click Save:

    Field

    Value

    Label

    Ticket Attachment

    Plural Label

    Ticket Attachments

    Object Name

    TicketAttachment

  5. Click Actions (Actions) for the new object and select Edit ERC.

  6. Enter TICKET_ATTACHMENT and click Save.

  7. Click Add Field or Relationship and select Add Field.

  8. Enter these values and click Save.

    Field

    Value

    Label

    Title

    Field Name

    title

    Type

    Text

    Enable Entry Translation

    No

    Mandatory

    Yes

    Accept Unique Values Only

    No

  9. Repeat the above step to add these fields:

    Field

    Value

    Label

    Description

    Field Name

    description

    Type

    Text

    Enable Entry Translation

    No

    Mandatory

    No

    Accept Unique Values Only

    No

     

    Field

    Value

    Label

    File

    Field Name

    file

    Type

    Attachment

    Request Files

    Upload Directly from the User’s Computer

    Show Files in Documents and Media

    No

    Mandatory

    Yes

  10. Click Publish, check Ticket Attachment, and click Publish Objects to confirm.

  11. Confirm the object is published successfully and click Close.

After creating the object definition, you can relate it to the Ticket object and enable inheritance.

Exercise: Relating the Ticketing Objects

When you define one-to-many relationships, you can enable inheritance, designating the parent object as the root for the child object. Here you’ll create a one-to-many relationship between the Ticket and Ticket Attachment objects and enable inheritance as the Clarity Admin user.

  1. In the Object Model Builder, drag a line from the Ticket object to the Ticket Attachment object to create a relationship.

  2. Enter these details:

    Field

    Value

    Label

    Ticket to Attachments

    Name

    ticketToAttachments

    Type

    One to Many

    One Record Of

    Ticket

    Many Records Of

    Ticket Attachments

    Enable Inheritance

    Yes

     

    Enter these details for the relationship.

  3. Click Save.

You've designated Ticket as the root object for Ticket Attachment. For a complete list of what this entails, see Using Object Inheritance.

Exercise: Creating the Ticket Comment Object

A single object definition can have multiple parents, even though each individual entry belongs to only one parent at a time. Because of this, Clarity can create a single Ticket Comment object and relate it to both the Ticket and Ticket Attachment objects as a child. Here you’ll set up this object and its relationships as the Clarity Admin user.

  1. Open the Global Menu (), go to the Control Panel tab, and click Objects.
  2. Go to the Ticketing folder.

  3. Click View in Model Builder.

  4. Click Create New Object, enter these values, and click Save:
     

    Field Value
    Label Ticket Comment
    Plural Label Ticket Comments
    Object Name TicketComment
  5. Click Actions () for the new object and select Edit ERC.

  6. Enter TICKET_COMMENT and click Save.

  7. Click Add Field or Relationship and select Add Field.

  8. Enter these values and click Save.
     

    Field Value
    Label CommentText
    Field Name commentText
    Type Text
    Enable Entry Translation No
    Mandatory Yes
    Accept Unique Values Only No
  9. Click Publish, check Ticket Comment, and click Publish Objects to confirm.

  10. In the Object Model Builder, drag a line from the Ticket object to the Ticket Comment object to create a relationship.

  11. Enter these values and click Save:
     

    Field Value
    Label Ticket to Comments
    Name ticketToComments
    Type One to Many
    One Record Of Ticket
    Many Records Of Ticket Comments
    Enable Inheritance Yes
  12. Drag a line from the Ticket Attachment object to the Ticket Comment object to create a second relationship.

  13. Enter these values and click Save:
     

    Field Value
    Label Ticket Attachment to Comments
    Name ticketAttachmentToComments
    Type One to Many
    One Record Of Ticket Attachment
    Many Records Of Ticket Comments
    Enable Inheritance Yes
  14. Verify both relationships appear with Ticket Comment shown as a child of both Ticket and Ticket Attachment.

     


Great! You've configured Ticket Comment as a child with two root objects. Each individual comment entry will inherit from either Ticket or Ticket Attachment based on its related entry.

Conclusion

A well-designed inheritance model centralizes access control and reduces structural duplication across related entities. Using object inheritance, you can build scalable data models that streamline object management across every entity within your application.

Next, you’ll review what you’ve learned before moving on to the next module.

Loading Knowledge