Configuring fields
Fields model data in your application UI and define what information you need to provide to reach your business goals.
For example, in a process of hiring new employees, you can create properties that correspond with the personal details of a candidate, such as a name, a surname, and an address.You can adjust the type of your field to match the data that you want to collect, and
pair the field automatically with a control in the UI. For example, if you want the
candidate to provide an email address, you can set up a field with the type
email.
In the user interface, the system renders the field as an Email control. To make the development process more
efficient, each field type defaults to the most intuitive control, such as a checkbox for a Boolean expression.
Field types
The following table presents available fields:
Field type | Description | Configuration | Example (editable) |
Text (single line) | Captures alphanumeric values from a single line of text. You can define a maximum length for the text input field, which determines the number of characters that are exposed in the database entry for that field's value. For example, you can use this field to capture the patient's name. | Configuring common field settings | Text |
Text (paragraph) | Captures alphanumeric values from a box with multiple lines of text. You can define a maximum length for the text input field, which determines the number of characters that are exposed in the database entry for that field's value. With additional field configuration, you can decide whether this field captures text in markup, or just plain text. For example, you can use this field to capture the description of symptoms that the patient provides. | Configuring common field settings | |
Boolean | Captures true or false values. By default, the UI control for that field is a checkbox. For example, you can use this field to capture the patient's agreement for storing their personal information. | Configuring common field settings | Boolean |
Currency | Captures positive and negative decimal numeric values. The UI displays the field with a currency code that reflects the default currency type for the application user. For example, you can use this field to capture a cost of a medical procedure. | Configuring a Currency field | Currency |
Date & time | Captures values for date and time, which Pega normalizes to a GMT format. The UI displays the field value in a localized format for the user. For example, you can use this field to capture the date and time of the patient's appointment. | Configuring a Date Time field | Date Time |
Date only | Captures values for a date, which Pega normalizes to a GMT format. The UI displays the field value in a localized format for the user, taking into consideration the standards for digit grouping and decimal separators of the localized format. For example, you can use this field to capture the patient's date of birth. | Configuring a Date Time field | Date Time |
Decimal | Captures positive and negative decimal numeric values. For example, you can use this field to capture the patient's weight. | Configuring Decimal fields | |
Captures alphanumeric values that must pass a regular expression validation for a correct email address format; the input must include the at sign (@) followed by a domain. The UI displays the field value as a link that launches the user's default email application. For example, you can use this field to capture the patient's email address. | Configuring common field settings | ||
Integer | Captures positive and negative whole numeric values, including zero (0). For example, you can use this field to capture the patient's age. | Configuring Integer fields | |
Percentage | Captures positive and negative decimal numeric values that the application displays as a percentage. For example, you can use this field to display the body fat percentage after the patient's examination. A field value of 0.25 equals 25%. | Configuring Percentage fields | Number |
Phone | Captures numeric values. The field validates the user's input to conform to the region-specific phone number format. The UI displays the field value as a link that initiates a phone call on a mobile device. For example, you can use this field to capture a patient's contact number. | Configuring common field settings | Phone |
Picklist | Captures an alphanumeric value that is a single choice from a list of valid options. You can define various sources for picklists, such as data pages or other field values. For example, you can use this field to capture a patient's marital status. | Configuring Picklist fields | |
Time only | Captures values for time, which Pega normalizes to a GMT format. For example, you can use this field to capture a patient's preferred appointment time. | Configuring a Date Time field | Date Time |
URL | Captures alphanumeric values that must pass a validation for a correct URL format; the input must begin with http:// or https:// and be followed with any string. The UI displays the field value as a link that launches the user's default browser with the target web address. For example, you can use this field to display an external web address of a medial facility where a patient can book a procedure. | Configuring common field settings | URL |
Attachment | Captures files through drag-and-drop or selecting files on the
user’s device. For example, you can use this field to receive PDF files with the patient's test results. | Configuring common field settings | File |
Location | Captures coordinates for geolocation. For example, you can use this field to display an address where a patient needs to deliver a testing sample. | Configuring common field settings | Location |
User reference | Captures a single choice from a list of all system operators that have access to the application. This field is a special linked field that stores a list of operators who have access to the application. Depending on your configuration, the UI displays the field as a search box or a drop-down list. For example, you can use this field to help a patient pick a primary doctor from a list of doctors that have access to the application. The application can use that choice to directly route work items to the chosen doctor. | Configuring fields associated with case and data objects | |
Case reference | Captures single or multiple records that the system sources from a selected case type. The UI displays the field as a drop-down in which users can choose one (single record) or multiple (list of records) options from a given case type. For example, you can use this field in the Appointment case to reference one or more medial procedures from the Medical procedure case. | Configuring fields associated with case and data objects | |
Data reference | Captures single or multiple records that the system sources from a selected data object. The UI displays the field as a drop-down in which users can choose one (single record) or multiple (list of records) option from a given data object. For example, you can use this field in the Appointment case to reference data from the Patient data object. | Configuring fields associated with case and data objects | |
Embedded data | Captures single or multiple records from the user-supplied data that the application stores and sources from inside a case instance or a work object. For example, you can use this field to capture a patient's billing address, based on the home address they already provided in the case. | Configuring fields associated with case and data objects | |
Query | Captures single or multiple records from a data page or a view that the application stores and sources from outside a case type (other applications or systems). For example, you can use this field to present users with a list of medical facilities in a patient's city of choice, which are sourced from an external site. | Configuring fields associated with case and data objects |
- Configuring a data model for a case
Configure a data model to define the data that you want to use in a case. For example, to include a user email address in a case, add an email address field to the data model.
- Configuring common field settings
Improve the presentation of your user interface by configuring out-of-the-box fields. By adjusting options such as visibility, helper text, or on-click behavior, you can adapt the controls to the needs of your business, and build a cleaner, more intuitive user experience.
- Configuring a Currency field
Collect and display monetary information in a field that automatically formats the amount by adding language-specific separators and a currency-specific symbol, such as the dollar sign.
- Configuring a Date Time field
Standardize date and time formats and reduce the number of input mistakes by using a Date Time field. When you set up a Date Time field, you ensure that users enter scheduling information in the right format.
- Configuring Decimal, Integer, and Percentage fields
Collect numerical information by using a standard field that checks if the user-provided format of data is correct. Create clean, intuitive forms for your users with less effort by selecting the field type that best matches your business needs.
- Configuring Picklist fields
Reduce the number of user input errors by providing the users of your application with a list of values from which to choose. A Picklist field captures a single choice from a list of valid options presented as radio buttons or drop-down lists.
- Configuring fields associated with case and data objects
A data object is a template for describing an entity through fields, such as name and address. Depending on your business needs, data objects can reference a list or a single record, and source their information from internal or external databases. This flexibility of approach ensures optimal reuse and better data management.
- Configuring cascading drop-down lists
Reduce the time that is needed to complete a form by creating a group of drop-down lists that take cues from each other, and adjust the available options depending on choices that the user makes in the interface.
- Using conditional logic in Cosmos React
Define the logic that governs the behavior of fields in your application more intuitively with the condition builder. By creating conditions, you can link the visibility and availability of certain parts of your UI to your business needs, and build a cleaner, less cluttered application.
- Creating a When rule
Evaluate a Boolean logical statement that involves comparisons among values of properties, to return true or false, by creating a When rule.
Previous topic Configuring forms Next topic Configuring a data model for a case