Facility entity
Pega Government Platform provides data support to collect data about facilities in the form of Facility Entity.
The facility Entity feature contains a persistent datastore and three supporting case types to manage the Facility Entity datastore.
Add Facility case type
Add a facility case type to the system. Using the PegaPS-Work-Entity-Facility-Add case type, you can introduce a new entity of the type Facility into the system.
After you add a new facility and successfully submit, the details of the facility are persisted along with supported data, for example, Address.
Adding a new field to the facility intake screen
Capture a new field in the facility intake screen and persist it. You can add a new data field or property and extend the existing facility intake screen.
- Create a field, for example, Permission Date in the facility data type.
- Run the household case type and navigate to the Facility Information view.
- Click the Add icon and add the field created in step
1.
Introducing duplicate check validation for a field
Create duplicate check fields and update them with new fields.
- Create the CheckDuplicate (PegaPS-Data-Entity-Facility) case match rule.
- Add a new field by clicking Add must match condition, similar to how you add for Vehicle entity.
- Update the filter logic accordingly.
- Create an activity: CheckDuplicate (PegaPS-Data-Entity-Facility), and include the steps 2 and 3 by referring to the activity of the Vehicle entity.
- Create a post processing activity for FacilityOverview
(PegaPS-Work) and invoke the new
CheckDuplicate
activity as a first step in the activity with the step page as.Facility
and in the second step, send a warning message when the property value.Facility.IsDuplicate
is true.
Adding a new list item
Update an existing list of items with new items.
- In Dev Studio, to add a new list item, create a data type Service in the PegaDATA database and have the following properties pyID (Primary key), EntityID, and EntityType.
- Add other properties related to inspection like inspected by, inspected on, and so on.
- In the Facility data type (PegaPS-Data-Entity-Facility),
create a field.
- In the Field name box, enter InspectionList.
- In the Type list, select Embedded data.
- In the Data object list, select Inspection.
- Click Submit.
- Update the PersitEmbeddedPage (PegaPS-Data-Entity-Facility) activity with a new step looping the InspectionList property and invoke the activity SaveObject by passing the EntityID and EntityType parameters similar to CommList.
- Create a UI to capture the facility details so that they persist after you enter the data.
Update Facility case type
Update the existing facility case type. Using the PegaPS-Work-Entity-Facility-Update case type, you can update the details of an existing entity.
The Update facility case type fetches the details of the Facility entity that needs to be updated. You can make changes to the facility data and submit them. The details persist after you submit.
The D_Facility data page fetches the entity details along with associated data, like Address, Communication, and so on.
Updating an existing list property
Update an existing list property, for example, InspectionList.
Fetch the facility details to update the list of item details in a facility that are captured as a part of Add Facility.
- Update the FetchFacilityDetails (PegaPS-Data-Entity-Facility) data transform.
- Add a step similar to AddressList.
View Facility case type
View the details of a facility entity. Using the PegaPS-Work-Entity-Facility-View temporary case type, you can view the complete details of an existing facility entity.
The Details (PegaPS-Data-Entity-Facility) wrapper section contains all the facility related views or sections.
Adding a field to the facility view
Add new fields to the existing facility view.
- To add the field, navigate to the Details wrapper section and choose the
appropriate section to show the field, for example, the Facility
header RO section.
- Add the new field along with the existing ones.
Showing captured list details in the facility view
Show the captured list, for example, InspectionList details in the facility view.
- Create a view or section in PegaPS-Work-Entity-Facility-View class.
- Include the section in the Main content region of the
pyCaseMainInner view.
Search entities
Search for information across multiple record types. The search entities feature returns real-time results in entity data.
You can directly access the search page of an entity from the navigation panel. Each entity has its own landing page for search. You can build a landing page for an entity using the associated harness.
The following table shows the list of harnesses for each entity:
Entity | Harness class | Harness name |
Person | PegaPS-Data-Portal | Person |
Business | PegaPS-Data-Portal | Business |
Facility | PegaPS-Data-Portal | Facility |
Vehicle | PegaPS-Data-Portal | Vehicle |
Household | PegaPS-Data-Portal | Household |
Entity | Data page | Report definition |
Person | D_PersonList | PersonList |
Business | D_BusinessList | BusinessList |
Facility | D_FacilityList | FacilityList |
Vehicle | D_VehicleList | VehicleList |
Household | D_SearchHouseholdList | SearchHouseholdList |
Entity | Section Class | Section name |
Person | PegaPS | SearchPersonTable |
Business | PegaPS | SearchBusinessTable |
Facility | PegaPS | SearchFacilityTable |
Vehicle | PegaPS | SearchVehicleTable |
Household | PegaPS | SearchHouseholdTable |
Introducing new search criteria
Complete the following steps to introduce new search criteria for an entity:
- Open the data page and the report definition of the entity.
- Add the new search criteria as a parameter.
- Update the filer logic of the report definition with the appropriate relationship.
- Add the property in the Edit columns list of the report definition.
- In the section, pass the search text to the newly added parameter of the data page. If you cannot view the parameter, reselect data page.
- Add the property as a column to the table in the section.
Previous topic Household entity Next topic Entity attachments