Model-driven UI Controls
With Constellation, the UI is primarily dictated by the Data Model. The Data Model includes the Data Objects defined in the application Data Model and data relationship Field Types (Embedded Data, data reference, Case reference, and query) used to associate them with the Case Type Data Model, as well as the simple fields and Field Types defined with the Case Type Data Model. The UI controls available to you when you author Views in Pega Platform™ are determined by the fields, and more importantly, the corresponding Field Types defined in your Case Type Data Model.
The Picklist Field Type
The Case Type Data Model includes an option for designing a field with the Picklist Field Type. When designing the field, using a Picklist automatically determines the UI display options for that field:
- Drop-down list – best when the number of records to choose from is limited and viewing one record at a time is preferred.
- Search box – best when you need to display more than one property and there are many records to choose from.
- Radio buttons – best when the number of records to choose from is limited.
The Cascading-dropdown pattern
You can use two related fields, both defined with the Picklist Field Type, to define a View with a cascading drop-down pattern.
Business requirements for an application often require the choices associated with one field to be restricted based on the choice of an earlier field. For example, the selection of an Industry name is based on the earlier selection for the Industry sector field, as seen in the following image:
Constellation UI provides you with tools that support dynamic field behavior in forms through convenient configuration patterns, like the cascading drop-down. Dynamic field behavior can help your users process forms more quickly, for example by pre-populating fields with suggested values or by narrowing down choices in a control.
This is the Constellation advantage in Pega Platform: the most common Case management patterns are built into the Data Model design options.
Additional Field Types and UI control relationships
Like the picklist, each Field Type has its own associated UI control. Additional Field Types and their associated UI controls include:
Location
The Location Field Type is used to store location data. At run time, the UI control for Location is an embedded Google Map.
Currency
The Currency Field Type, rather than the Decimal Field Type, is used when the field is used in reference to money because it includes currency codes and the appropriate decimal and comma-separators for the currency.
Text (single line)
The Text (single line) Field Type is used for numerical fields (for example, Account number or Customer number), where comma separators are not wanted. Additionally, Email and URL Field Types are used instead of Text (single line) because they include out-of-the-box validation for email and URL text patterns.
Embedded Data (List of Records)
The Embedded Data Field Type is used to create a relationship between a Data Object and a Case Type. In a field with an Embedded Data Field Type, a record or list of records entered by a user is associated with a Case instance.
The Embedded Data Field Type supports the following modes:
- Single record
- List of records
When authoring a View in Pega Platform, the UI control options for an embedded list of records are a table or a field group. The table is displayed differently depending on whether the field is set to Editable or Read-only, as seen in the following figures:
The Editable table:
The Read-only table:
Additionally, the field group approach provides another way to display an embedded list of records. A field group is useful when you need a more structured and detailed view of each record in the list. Understanding when to use a table versus a field group depends on the complexity and format of the data you need to present. Tables are ideal for simpler data, while field groups are better for complex data structures where each record requires multiple fields for detailed information.
Case reference
The Case reference Field Type is used for conveniently selecting a previously created Case from within the current Case to create a Case-to-Case relationship. The UI control options for a Case reference are Autocomplete, Dropdown, and Table.
The following image shows a Case reference table:
The following image shows a Case reference dropdown:
The following image shows a Case reference autocomplete:
Data reference
The Data reference Field Type is used for conveniently searching and selecting information related to a Data Object whose records are sourced either from the Pega Database or from an external system of record.
The Data reference Field Type supports the following modes:
- Single record
- List of records
- Many to Many
Each mode has its own associated UI controls. For example, the list of records mode supports Table, Simple Table, Combobox, and Checkbox Group.
The following image shows a Data reference simple table:
The following image shows a Data reference combobox:
The following image shows a Data reference checkbox group:
Query
The Query Field Type is used for capturing single or multiple records from a Data Page or a View that the application stores and sources from outside of the Case Type.The Data Page defines parameters that the Query data relationship is configured to use.
This is small sample of Data Model configurations and their associated UI controls and behavior.
The fields and configurations defined in your Case Type Data Model, in combination with Constellation, prescribe the UI for a clean and consistent user experience across channels and applications. If you design and model your Data Objects, fields and Field Types to best achieve the expected business outcome, your UI will largely build itself.
Check your knowledge with the following interaction:
This Topic is available in the following Module:
Want to help us improve this content?