Você está na página 1de 8

Exercise: Create Data Object Type and Property Record

Scenario
The process for employees to have expenses reimbursed is shown in the following illustration.

The following contact information is required to be entered on each voucher submitted for
reimbursement.

This contact information is collected for many applications. So, it has been determined that a new
data object type should be created that includes the employee contact information fields.
For this exercise, you will be performing the role of System Architect using the account generated by
the New Application Wizard (App Express).

User Name: Developer01


Password: password

Approach
This exercise provides an opportunity to see how you can create your own data object type that can
be used by any case type in the application. The data value properties in this data object type can
also be used to simplify creation of UI for collecting employee contact information.
From the Data explorer, create a data object type named ContactInfo that includes contact
information for an employee, as shown in the Scenario.
Use this data object type to define a data model property (named Employee Contact Information,
with a short name of EmpContInfo) that can be used from any case type within the application.

Hints
Whencreatinganewdataobjecttype,notesomeofthefollowing:

Data Object Type is created in Data.

Property Record that is modeled on new Data Object Type is created in Work.

Procedure
Part 1 - Follow the steps below to add a data object that can be used from anywhere in the
application.
1. Click the Data explorer icon to open the data explorer, open the Manage Data Objects menu
and select Add/remove data object types to add a new data class.

2. In the Data Object Types screen, click Create New to create a new data class.

3. In the Display Name field, enter ContactInfo and then expand ID, INTERITANCE AND
RULESET SETTINGS.

4. The new class youre defining can inherit properties from one or two parents. The details of
inheritance are beyond this level of training, but will be summarized to help you correctly fill
out the Data Object Type rule form.
Directed parent class inheritance allows you to specify an immediate parent. For this
exercise, use Data-Party. Begin typing Data-Party and then use the down-arrow () to find it
in the list. When Data-Party is highlighted, select it by pressing the Enter key.

5. Pattern parent class inheritance searches through all classes linked in the hierarchy of the
pattern specified. To keep within our application, use the down-arrow () to search for the
organization that owns this application (MainCo) concatenated with the application name
(EmpReimb) concatenated with the word Data.

6. Click OK.

7. Add the properties listed below to the Contact Information data object type (class). Note
that all property types will remain as the default Text. Click Next to continue.

8. View property details and then click Next.

9. Confirm property creation by clicking Submit.

10. After clicking Submit, a data object type (class) has been defined in the Data class. To view
the data object type, click the App explorer icon , begin to type MainCo-EmpReimb-D into
the auto complete form at the top of the application explorer and then use the down arrow
to select MainCo-EmpReimb-Data. Expand ContactInfo > Data Model > Property. You
may need to refresh the Application Explorer to see the new data object type.

Next, allocate a data page to store information of this object type.

Part 2 Follow the steps below to create a page property to hold contact information values.
1. Click the App explorer icon and then select MainCo-EmpReimb-Work as the context (begin
typing MainCo-EmpReimb and then use the down-arrow to select from auto-complete
choices). When the MainCo-EmpReimb-Work tree appears, right-click MainCo-EmpReimbWork and select Create Data Model Property from the menu.

2. Name the property record Employee Contact Information.


Note: For clarity and ease of use, give the property record the short name
EmpContInfo.
Ensure the Record Context is MainCo-EmpReimb-Work. Click Create and open.

3. Change the property from the default type Text to Single Page (since it will contain more
than a single value).

4. Specify that the values in this page will be defined by the ContactInfo data type that was
defined earlier in this exercise. Do this by starting to type MainCo-EmpReimb-DataContactInfo, and then using the down-arrow () to select from the list that pops up and
clicking Enter.
Note: If the ContactInfo data type appears in the Application Explorer data
class, but is not on the list, type it manually.
Click Save.

5. To view your results, go to the Application Explorer. Ensure you are viewing the Work class
and select Refresh from the Application Explorer menu. Then, expand Data Model
Property.

The resulting data model can now be used in any case within the Employee Reimbursements
application.

Você também pode gostar