Once you have the BPM object, you need to specify the type of data to be stored in it.
You do this by defining the attributes of the object. Each attribute holds one
particular piece of information.
We begin with data fields that are used only once per expense report (once per instance),
such as the name of the employee.
Note that the expense report form is numbered, but there is no "report number" in the
table in
Defining
the Expense Report. We leave the implementation of this number to you, so you
can test your skills once you have completed the tutorial.
We skip the Total attribute for now because it contains a calculated value. You
will add it in a later task.
To define the attributes:
-
In the Project Navigator, right-click on the ExpenseReport BPM Object
(
), and click
(
).
The
Attribute dialog box appears.
-
In the Name field, enter submittedBy .
-
Select String from the Type drop-down list, and click
OK.
The attribute editor for the
submittedBy attribute opens.
-
In the Storage Constraints section of the editor, select
Not Null. This tells Oracle BPM that the field is
mandatory.
-
Save
(
) the changes and close the editor window by clicking on the
X in the bottom tab. If you close from the top tab,
you close the BPM Object rather than just this attribute.
-
You now define the Submit Date attribute. Again, in the Project Navigator right-click on
the ExpenseReport BPM Object
(
), and click
(
).
The
Attribute dialog box appears.
-
Enter submitDate in the Name field.
The attribute editor for the submitDate attribute opens.
-
From the Type drop-down list, select Time.
The Time Precision list appears
-
From the Time Precision list, select Date Only.
-
As before, in the Storage Constraints section, check Not
Null.
-
Save
(
) the changes and close the editor window by clicking on the
X in the bottom tab.
-
By now you should be able to add attributes on your own. Add the remaining attributes
according to the following table:
| Name |
Type |
Additional Properties |
| description |
String |
Storage Constraints = Not Null |
| Maximum Length = 100 |
| costCenter |
Int |
none |
| reviewedBy |
String |
Storage Constraints = Not Null |
| comments |
String |
Storage Constraints = Not Null |
| Maximum Length = 400 |
| isApproved |
Bool |
Default Value = False |
You have now defined seven attributes in the ExpenseReport BPM object. In the
Project Navigator, you should see the following:
Figure 1. ExpenseReport BPM Object Attributes
In the next task, you add a group to this object. Groups are used to store arrays
or collections of attribute sets.