Sie sind auf Seite 1von 282

R12 Extend Oracle

Applications: Customizing
OA Framework Applications
Course Labs

Course Labs .....................................................................................................................................................1


R12 Customizing OA Framework Applications.............................................................................................3

Lab 1..............................................................................................................................................................4
Task 1: Login to Your E-Business Suite Instance .....................................................................................5
Task 2: About This Page Link ...................................................................................................................8
Solution......................................................................................................................................................14
Lab 2..............................................................................................................................................................25
Task 1: Preparation ....................................................................................................................................26
Task 2: Modify the FWKTEST User.........................................................................................................27
Task 3: Set-up the NX Client on Your Classroom PC...............................................................................29
Task 4: Open the NX Client on Your Classroom PC ................................................................................32
Task 5: Unzip Tutorial.zip.........................................................................................................................34
Task 6: Set Your JDeveloper Environment ...............................................................................................35
Task 7: Start JDeveloper............................................................................................................................36
Task 8: Get the DBC File ..........................................................................................................................38
Task 9: Test Your JDeveloper Workspace and Project .............................................................................39
Task 10: Set-up Your Database Connection..............................................................................................42
Task 11: Set Your Project Properties.........................................................................................................48
Task 12: Test Your JDeveloper Set-up......................................................................................................54
Task 13: Optional Personal Set-up .........................................................................................................57
Lab 3..............................................................................................................................................................58
Step 1. Setup your environment for OA Framework development............................................................59
Step 2. Create the Model-layer Components .............................................................................................61
Step 3. Create the View-layer Components...............................................................................................67
Lab 4..............................................................................................................................................................74
Task 1: Create a new responsibility for iExpenses ....................................................................................75
Task 2: Create a new responsibility for Manager Self Service ..................................................................77
Task 3: Create a new responsibility for iProcurement ...............................................................................78
Task 4: Create Your User ..........................................................................................................................79
Task 5: Test your own User.......................................................................................................................81
Task 6: Set Profile Options........................................................................................................................83
Task 7: Learn the Administrator-level Personalization UI ........................................................................88
Task 8: Create Administrator-seeded User-level Personalizations ............................................................90
Task 9: Test Your Administrator-seeded Personalizations........................................................................94
Task 10: Add a Tip to a Page.....................................................................................................................95
Task 11: Add Button links.........................................................................................................................98
Task 12: Rearrange the Regions on a Page................................................................................................100
Task 13: Add a Column to a Table - Analysis...........................................................................................102
Task 14: Add Column to the Table............................................................................................................105
Task 15: Reorder Table Columns ..............................................................................................................107
Task 16: Personalize Privacy Link Globally Across Pages .......................................................................108
Task 17: Disable Your Personalizations ....................................................................................................110
Task 18: Using the Functional Administrator............................................................................................112
Copyright Oracle Corporation, 2007. All rights reserved.

R12 Extend Oracle Applications: Customizing OA Framework Applications Table of Contents


xiv

Task 19: Make a Field Required................................................................................................................114


Lab 5..............................................................................................................................................................116
Task 1: Determine Which Flexfield to Set-Up ..........................................................................................117
Task 2: Define Descriptive Flexfield Segments ........................................................................................119
Task 3: Enable Descriptive Flexfield on Page ...........................................................................................124
Task 4: Create a new flexfield on the Non-Catalog Request Page ............................................................128
Task 5: Make Your Flexfield Visible to Your Responsibility ...................................................................131
Lab 6..............................................................................................................................................................133
Task 1: Set-up SQLDeveloper...................................................................................................................134
Task 2: Navigate Around the Database .....................................................................................................137
Task 3: Administer the Database ...............................................................................................................139
Solution Task 2.......................................................................................................................................140
Solution Task 3.......................................................................................................................................142
Lab 7..............................................................................................................................................................144
Task Navigate the File System ...............................................................................................................145
Solution - Navigate the File System ..........................................................................................................146
Lab 8..............................................................................................................................................................148
Task Administering the Server Processes...............................................................................................149
Solution Administering the Server Processes .........................................................................................150
Lab 9.............................................................................................................................................................152
Task Setting Up the Environment and Locating Utilities .......................................................................153
Solution Setting Up the Environment and Locating Utilities .................................................................154
Lab 10............................................................................................................................................................157
Task 1: Allow Personalizations .................................................................................................................158
Task 2: Personalize the Expenses Home Page...........................................................................................159
Task 3: Create folders on the server ..........................................................................................................162
Task 4: Set the Personalization Document Root Path Profile....................................................................164
Task 5: Export the Personalizations to File System...................................................................................165
Task 6: Edit the Personalizations...............................................................................................................168
Task 7: Change the Personalization Document Root Path Profile.............................................................170
Task 8: Import the Personalizations into the MDS repository...................................................................171
Lab 11........................................................................................................................................................... 173
Pre-requisites: ............................................................................................................................................174
Task 1: Copy all .class files to $JAVA_TOP ...........................................................................................176
Task 2: Import the Page and Region into the MDS ...................................................................................177
Task 3: Register the Page within E-Business Suite ...................................................................................178
Task 4: Bounce the E-Business Suite Instance ..........................................................................................179
Task 5: Test Your New Page .....................................................................................................................180
Task 6: Remove Your Metadata ................................................................................................................181
Lab 12............................................................................................................................................................186
Task 1: Design Your Menu........................................................................................................................187
Task 2: Research Your Menu ....................................................................................................................188
Task 3: Implement Your Function.............................................................................................................191
Task 4: Implement Your Menu..................................................................................................................192
Task 5: Implement Your Responsibility ....................................................................................................197
Task 6: Modify Your User and Test ..........................................................................................................198
Lab 13............................................................................................................................................................200
Task 1: Create a New Project ....................................................................................................................201
Task 2: Add Attributes to an Existing BC4J Object ..................................................................................203
Lab 14........................................................................................................................................................... 211
Task 1: Defaulting Attributes ....................................................................................................................212
Lab 15............................................................................................................................................................218
Task 1: Extend the BC4J Validation Logic ...............................................................................................219
Lab 16............................................................................................................................................................224
Supplemental Lab 1 .......................................................................................................................................236
Task 1: Create a new responsibility for iExpenses ....................................................................................237
Task 2: Create a new responsibility for Manager Self Service ..................................................................239
Copyright Oracle Corporation, 2007. All rights reserved.

R12 Extend Oracle Applications: Customizing OA Framework Applications Table of Contents


xv

Task 3: Create a new responsibility for iProcurement ...............................................................................240


Task 4: Create Your User ..........................................................................................................................241
Task 5: Test your own User.......................................................................................................................243
Task 6: Create User-level Personalizations ...............................................................................................245
Task 7: Duplicate Your User-level personalization...................................................................................251
Supplemental Lab 2 .......................................................................................................................................254
Task 1: Create a new responsibility for Sales ............................................................................................255
Task 2: Add the XXX Sales User responsibility to LJONES user.............................................................256
Task 3: Configure the Configurable Page..................................................................................................257
Supplemental Lab 3 .......................................................................................................................................268
Task 1: Use SPEL Syntax in Your Personalizations..................................................................................269
Task 2: Extending an Existing Region into a Page....................................................................................274
Task 3: Add a Region Using Url Include...................................................................................................277

Copyright Oracle Corporation, 2007. All rights reserved.

R12 Extend Oracle Applications: Customizing OA Framework Applications Table of Contents


xvi

Course Labs

Copyright Oracle Corporation, 2007. All rights reserved.

Copyright Oracle Corporation, 2007. All rights reserved.

R12 Customizing OA Framework Applications

Copyright Oracle Corporation, 2007. All rights reserved.

Lab 1

Copyright Oracle Corporation, 2007. All rights reserved.

Task 1: Login to Your E-Business Suite Instance


In this course, you have an E-Business Suite instance that is assigned to your terminal.
The E-Business Suite instance assigned to your terminal is for your and your partners,
if you have one, use. No other students in the class will share your E-Business Suite
instance.
Your instructor will tell you your E-Business Suite instance URL. Write that below:
My E-Business Suite URL is:
http://_______________________________________________

1. Open your Internet Explorer (IE) browser.


Note: Because of the Oracle University (OU) classroom set-up, you must use IE. IE
is not the only browser certified for use with an E-Business Suite instance. But, it is
the only browser properly configured on your PC (terminal).
2. Enter the URL for your E-Business Suite.
3. You will see the redirection screen which will look similar to the following:

Copyright Oracle Corporation, 2007. All rights reserved.

4. Login to the E-Business Suite as SYSADMIN/SYSADMIN. Click the Login button.

5. Click the Functional Administrator responsibility from the E-Business Suite


Navigator.

Copyright Oracle Corporation, 2007. All rights reserved.

6. The page should look similar to the following:

Copyright Oracle Corporation, 2007. All rights reserved.

Task 2: About This Page Link


1. Click the About this Page link shown on the footer (bottom) of the page.

Copyright Oracle Corporation, 2007. All rights reserved.

2. The page you see should look similar to the following:

3. The detailed steps to answer this question are shown at the end of this lab. But,
with what you know about OA Framework, and a little exploration, you should be
able to answer these questions.
4. What is the full name of the page? (complete path)
__________________________________________________________________
5. What is the version of the page?
__________________________________________________________________
6. What is the name of the pageLayout region (and therefore is the name of the
page)?
__________________________________________________________________
7. What is the root AM of the page?
__________________________________________________________________
8. What controller does the pageLayout region use?
__________________________________________________________________
Copyright Oracle Corporation, 2007. All rights reserved.

9. Is this the only controller used on the page? (Circle one)


YES / NO
10. Where is the page stored?
__________________________________________________________________
11. How is the page stored? (Circle one)
In XML only / In Java only / In both XML and Java / In text / In PL-SQL
12. Beneath the Page Definition region is a link titled, Expand All. Click the Expand
All link.
13. List four (4) UI web beans used on the page?
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
14. Is there more than one controller used on the page? (Circle one)
YES / NO
15. If Yes, what are the name(s) of the additional controllers?
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
16. What VO is being used by the UI objects?
__________________________________________________________________
17. Expand the Business Component References Details region.
18. What is the complete path to the AM?
__________________________________________________________________

Copyright Oracle Corporation, 2007. All rights reserved.

10

19. Are there any other AMs used by the page? (Circle one)
YES / NO
20. If Yes, list the other AMs used by the page?
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
21. Question 16 asked what VO was being used. What is the complete path to that
VO?
__________________________________________________________________
22. What is the EO associated to the VO from Question 16/21? (list the full path)
__________________________________________________________________
23. Does this page use any flexfields? (Circle one)
YES / NO
24. List the flexfield used by this page?
__________________________________________________________________
25. Click the GrantsResultsVO link to drill-down to the details of this VO.
26. What version is this VO?
__________________________________________________________________
27. Does this VO use an EO? (Circle one)
YES / NO
28. If Yes, list the complete name of this EO?
__________________________________________________________________
29. Does this EO have an associated EntityExpert? (Circle one)
YES / NO

Copyright Oracle Corporation, 2007. All rights reserved.

11

30. If Yes, list the full path name of the EntityExpert?


__________________________________________________________________
31. List the version of the EO from Question 28?
__________________________________________________________________
32. List four (4) attributes that are contained in the VO?
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
33. Click the Return to About Page link.
34. Click the Personalization tab.
35. List the Personalizations associated with this page?
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
__________________________________________________________________
36. Click the Page Context tab.
37. What User Name is being used on this page?
__________________________________________________________________
38. What Responsibility is this page using?
__________________________________________________________________
39. What is the Responsibility Key being used on this page?
__________________________________________________________________

Copyright Oracle Corporation, 2007. All rights reserved.

12

40. What Function is this page using?


__________________________________________________________________
41. Click the Technology Components tab.
42. What version of OA Extension is being used on this server?
__________________________________________________________________
43. Click the Java Systems Properties tab.
44. Where does APPL_TOP point to on this server? (list the complete path)
__________________________________________________________________
45. Click the Profiles tab.
46. Expand the Logging/Diagnostics region.
47. What is the value of the FND: Diagnostics profile option?
__________________________________________________________________
NOTE: FND: Diagnostics is the profile option that controls whether or not you see
the About this Page link. It must be set in order for you to see the link.
48. Click the Patches tab.
49. Have patches been applied to this E-Business Suite instance? (Circle one)
YES / NO
50. If Yes, list the last patch number applied to this server?
__________________________________________________________________
51. Click the Return to Page: Grants link.

Copyright Oracle Corporation, 2007. All rights reserved.

13

Solution

4. What is the full name of the page? (complete path)


/oracle/apps/fnd/security/grants/webui/GrantSummaryPG
5. What is the version of the page?
120.3
6. What is the name of the pageLayout region (and therefore is the name of the
page)?
Grants
7. What is the root AM of the page?
GrantSummaryAM
8. What controller does the pageLayout region use?
GrantSummaryCO

Copyright Oracle Corporation, 2007. All rights reserved.

14

9. Is this the only controller used on the page?


NO But, this is a trick question at this point. You have not expanded the items on
the page to see this. So, Bonus Points if you got this correct.
10. Where is the page stored?
In the MDS. All OA Framework pages are stored there.
11. How is the page stored?
In XML only
12. Beneath the Page Definition region is a link titled, Expand All. Click the Expand
All link.

13. List four (4) UI web beans used on the page?


Any 4 of the following: stackLayout, header, tableLayout, rowLayout, cellFormat,
styledText, messageTextInput, messageRadioGroup, messageLovInput,
submitButton, table, messageStyledText, image, flowLayout, sortableHeader, link,
pageButtonBar

Copyright Oracle Corporation, 2007. All rights reserved.

15

14. Is there more than one controller used on the page?


YES As mentioned earlier. It was a trick question. Now, as you scroll down through
the UI objects, you will see that a second controller is mentioned.
15. If Yes, what are the name(s) of the additional controllers?
GrantResultsCO

16. What VO is being used by the UI objects?


GrantResultsVO
17. Expand the Business Component References Details region.

Copyright Oracle Corporation, 2007. All rights reserved.

16

18. What is the complete path to the AM?


oracle.apps.fnd.security.grants.server.GrantSummaryAM
19. Are there any other AMs used by the page?
NO
20. If Yes, list the other AMs used by the page?
There are no other AMs. Trick question of sorts.
21. Question 16 asked what VO was being used. What is the complete path to that
VO?
oracle.apps.fnd.security.grants.server.GrantResultsVO
22. What is the EO associated to the VO from Question 16/21?
oracle.apps.fnd.schema.security.grants.server.GrantEO
23. Does this page use any flexfields?
NO
24. List the flexfield used by this page?
There are no flexfields. Trick question of sorts.
25. Click the GrantsResultsVO link to drill-down to the details of this VO.

Copyright Oracle Corporation, 2007. All rights reserved.

17

26. What version is this VO?


120.0

27. Does this VO use an EO?


YES But, it is a trick question. You already answered this. But, if you scroll down
on this page, you can see additional information on the EO.
28. If Yes, list the complete name of this EO?
See Question 27. oracle.apps.fnd.schema.security.grants.server.GrantEO
29. Does this EO have an associated EntityExpert?
YES
30. If Yes, list the complete name of the EntityExpert?
oracle.apps.fnd.schema.security.grants.server.GrantEntityExpert

Copyright Oracle Corporation, 2007. All rights reserved.

18

31. List the version of the EO from Question 28?


120.1

32. List four (4) attributes that are contained in the VO?
List any 4 of the following: GrantGuid, GranteeType, GranteeKey, MenuId,
ObjectId, InstanceType, StartDate, EndDate, GranteeName, ObjectName,
MenuName, SetType, GrType, PsetType, InsType, Name, ObjType,
LastUpdateDate, ProgramTag, Date, AccessPolicy, InstanceSetName,
InstanceSetId
33. Click the Return to About Page link.

Copyright Oracle Corporation, 2007. All rights reserved.

19

34. Click the Personalization tab.

35. List the Personalizations associated with this page?


Trick question. There are no personalizations.
36. Click the Page Context tab.

37. What User Name is being used on this page?


SYSADMIN

Copyright Oracle Corporation, 2007. All rights reserved.

20

38. What Responsibility is this page using?


Functional Administrator
39. What is the Responsibility Key being used on this page?
FND_FUNC_ADMIN
40. What Function is this page using?
FND_GRANTS_SUMMARY
41. Click the Technology Components tab.

42. What version of OA Extension is being used on this server?


10.1.3 Build 809

Copyright Oracle Corporation, 2007. All rights reserved.

21

43. Click the Java Systems Properties tab.

44. Where does APPL_TOP point to on this server? (list the complete path)
/appltop/apps/apps_st/appl
45. Click the Profiles tab.

Copyright Oracle Corporation, 2007. All rights reserved.

22

46. Expand the Logging/Diagnostics region.

47. What is the value of the FND: Diagnostics profile option?


Y
NOTE: FND: Diagnostics is the profile option that controls whether or not you see
the About this Page link. It must be set in order for you to see the link.

Copyright Oracle Corporation, 2007. All rights reserved.

23

48. Click the Patches tab?

49. Have patches been applied to this E-Business Suite instance?


YES
50. If Yes, list the last patch number applied to this server?
5905539
51. Click the Return to Page: Grants link.

Copyright Oracle Corporation, 2007. All rights reserved.

24

Lab 2

Copyright Oracle Corporation, 2007. All rights reserved.

25

Task 1: Preparation
This lab takes you through setting up the user for your course.
Throughout this course, you will be asked to designate your name, or some other
unique identifier. You can use your initials. You can use your classroom terminal
number. The only requirement is that it is unique to you. Once you have selected that
designation, use it consistently throughout the remainder of the course.

Important Information:
You need to get the following from your instructor:
Your Host:

________________________________________________

Your SID:

________________________________________________

Your EBS Login:

http://___________________________________________

Default E-Business Suite Logins:


SYSADMIN/SYSADMIN
FWKTESTER/FWKDEV

Default Linux Machine Logins: (case-sensitive)


nxuser1/oracle
oracle/oracle
applmgr/applmgr

Copyright Oracle Corporation, 2007. All rights reserved.

26

Task 2: Modify the FWKTEST User


You need to modify an existing user account on your server. That user account is
FWKTESTER.
1. Login to the E-Business Suite as SYSADMIN/SYSADMIN
2. From the Home Page, select the
a. System Administrator responsibility
b. Security : User > Define form
3. When the Users form open, do the following:
a. Press the F11 key to start the query.
b. Type FWKTESTER into the User Name field.
c. Press the CTRL-F11 key to execute the query.
d. Tab to the Password field, and type ORACLE as the password.
e. Press the Tab key, which will return to the Password field. Re-enter
ORACLE as the password.
f. In the Direct Responsibilities region, click any listed responsibility, and
then click the New button on the button bar as shown.

g. Add the responsibility, OA Framework ToolBox Tutorial, to the


FWKTESTER user.
h. Click the New button.
i. Add the responsibility, OA Framework ToolBox Tutorial Labs, to the
FWKTESTER user.

Copyright Oracle Corporation, 2007. All rights reserved.

27

j.

Click the Save icon on the button bar to commit your changes.

k. Close the forms-based window, and return to the E-Business Suite


homepage.
l.

Logout of the E-Business Suite instance.

4. Login to the E-Business Suite instance as FWKTESTER/ORACLE.


5. You are logging in to the FWKTESTER responsibility for the first time. EBusiness Suite will require you to change the password. Change the password to
FWKDEV.
6. You will go to the E-Business Suite home page, which should look similar to the
following:

7. You can now exit the E-Business Suite instance.

Copyright Oracle Corporation, 2007. All rights reserved.

28

Task 3: Set-up the NX Client on Your Classroom PC


1. Double-click the NX Client for Windows icon. Or, if your system is already set-up,
double-click the specific NX Client session icon.

2. If not already set-up, the NX Connection Wizard will open. Click the Next button
to continue with the NX Connection Wizard.

3. Set your Session to the same as your SID name. Set your Host as indicated by
your instructor. Set the Internet Connection Type slider to WAN. Click the Next
button.

Copyright Oracle Corporation, 2007. All rights reserved.

29

4. Accept the defaults on the page. Click the Next button to continue.

5. Accept the defaults on the final page. Click the Finish button to continue. (Note:
You can ignore any screens that appear after you click the Finish button. If
necessary, click the OK buttons on any screens that might appear.)

Copyright Oracle Corporation, 2007. All rights reserved.

30

Copyright Oracle Corporation, 2007. All rights reserved.

31

Task 4: Open the NX Client on Your Classroom PC


1. Your desktop should appear similar to the following:

2. Double-click the Session icon (vx0321, as an example).

3. The Login user default is nxuser1, and that is correct. The password is oracle.
Click the Login button to login to your server. When the NX Client finally logs in,
you will see a screen similar to the following:

Copyright Oracle Corporation, 2007. All rights reserved.

32

Copyright Oracle Corporation, 2007. All rights reserved.

33

Task 5: Unzip Tutorial.zip


1. Open a terminal window. Click the terminal window icon in the toolbar at the
bottom of the window.

2. A terminal window will open, and it will look similar to the following:

3. At the command prompt input the following commands:


mkdir jdevhome
cd jdevhome
unzip /JDev/jdevbin/Tutorial.zip

Copyright Oracle Corporation, 2007. All rights reserved.

34

Task 6: Set Your JDeveloper Environment


1. Continuing in the same terminal window, input the following command:
export JDEV_USER_HOME=/home/nxuser1/jdevhome/jdev
2. You can also set your E-Business Suite environment at this point. In the terminal
window, input the following command:
. /appltop/apps/apps_st/appl/VX0321_vx0321.env
Note: The example command shown assumes that the SID is VX0321, and the Host
is vx0321 (without the .us.oracle.com, in the complete path). Your SID and Host
names will change.
Note: While difficult to discern in print, there is a <space> in the command shown
between the . (period) and the /appltop directory path.

Copyright Oracle Corporation, 2007. All rights reserved.

35

Task 7: Start JDeveloper


1. Continuing in the same terminal window, input the following command:
/JDev/jdevbin/jdev/bin/jdev&
Note: It is important to include the ampersand (&) at the end of the command to
allow your terminal window to continue to be used.
2. If the migration window appears, click the No button.

3. JDeveloper 10g with OA Extension will load, and it will appear similar to the
following:

Copyright Oracle Corporation, 2007. All rights reserved.

36

4. Deselect the Show tips at startup checkbox.


5. Click the Close button.
6. Hover over the Start Page tab, and the (X) (Close) icon will appear. Click the
Close icon to close the Start Page.

7. Minimize JDeveloper to complete Task 7.

Copyright Oracle Corporation, 2007. All rights reserved.

37

Task 8: Get the DBC File


1. In the terminal window, input the following commands:
cd $JDEV_USER_HOME/dbc_files/secure
cp $INST_TOP/appl/fnd/12.0.0/secure/VX0321.dbc ./
Note: The cp (copy) command is an example. Your DBC file will be named based on
the SID for your instance.

Copyright Oracle Corporation, 2007. All rights reserved.

38

Task 9: Test Your JDeveloper Workspace and Project


1. Maximize JDeveloper.
2. From within JDeveloper, do the following:
(Menu) File > Open
Double-click the myprojects folder icon to drill-down to that directory.
Double-click the toolbox.jws file icon to open that specific workspace.
3. When you open the workspace, you may encounter the Migration Warning
window. If you do, click the Yes button to continue.

4. If you encountered the Migration Warning, when the migration is complete you
will see the Migration Progress window. Click the OK button to continue.

Copyright Oracle Corporation, 2007. All rights reserved.

39

5. You may encounter the Business Components Upgrade window. If you do, click
the OK button to continue.

6. If you encountered the Business Components Upgrade window, when the


upgrade is complete you will encounter the Connections warning. This is
expected behavior. You have not yet defined a database connection for
JDeveloper to test your BC4J objects. Defining this database connection will be
the next step we perform. Click the OK button to continue.

7. JDeveloper will open the toolbox workspace. It will appear similar to the
following:

Copyright Oracle Corporation, 2007. All rights reserved.

40

8. Expand the toolbox workspace. Click the [+] icon beside toolbox in the
Applications Navigator window.

Copyright Oracle Corporation, 2007. All rights reserved.

41

Task 10: Set-up Your Database Connection


1. Click the Connections tab, and open the Connections panel.

2. Right-click the Database folder, and select New Database Connection.


3. The Create Database Connection wizard will open. Click the Next button to
continue.

Copyright Oracle Corporation, 2007. All rights reserved.

42

4. Set the Connection name to your SID.

5. Click the Next button.

Copyright Oracle Corporation, 2007. All rights reserved.

43

6. Set the username to apps.


7. Set the password to apps.
8. Click the Next button to continue.

Copyright Oracle Corporation, 2007. All rights reserved.

44

9. Set the Host Name to your host name.


10. Set the SID to your SID.
11. Click the Next button to continue.

Copyright Oracle Corporation, 2007. All rights reserved.

45

12. Click the Test Connection button.


Note: You should see a Success! message in the Status: window. If you do not see
the Success! message, click the Back button, resolve any errors in the settings, and
return to the test screen to click the Test Connection button. Do not click the Finish
button until you receive the Success! message.
13. If the test was a success, click the Finish button.

Copyright Oracle Corporation, 2007. All rights reserved.

46

14. When you exit the Create Database Connection wizard, you will return to the
Connections panel. It will appear as follows:

Note: You have two connections. The connection you just created (VX0321, as an
example) and fwk12dev. Fwk12dev is a default connection provided in JDeveloper.
It will not work. You can delete this connection if you like. Otherwise, just ignore it.

Copyright Oracle Corporation, 2007. All rights reserved.

47

Task 11: Set Your Project Properties


1. Click the Applications Navigator tab to open the Applications Navigator panel.

2. Double-click the Tutorial project, or right-click the Tutorial project, and select
Project Properties. This will open the Project Properties window that appears
similar to the following:
Note: If a migration window appears, click the OK button. You can safely ignore any
warning messages.

Copyright Oracle Corporation, 2007. All rights reserved.

48

3. Click the Business Components category. It will appear similar to the following:

Copyright Oracle Corporation, 2007. All rights reserved.

49

4. Select your Connection (for example, VX0321) from the poplist.


5. Click the Edit button.

Copyright Oracle Corporation, 2007. All rights reserved.

50

6. When the Edit Database Connection window opens, click the Test tab.
7. Click the Test Connection button.
8. You should see the Success! message.
9. Click the OK button to return to the Project Properties page.
10. Expand the Oracle Applications category, within the Project Properties window,
by clicking the [+] icon.
11. When you expand this category for the first time, you may get the following Login
window. Accept the defaults, which are User Name is apps, and Password is
apps.
12. Click the OK button to continue.

Copyright Oracle Corporation, 2007. All rights reserved.

51

13. Select the Runtime Connections subcategory. Your screen should look similar to
the following:

14. The DBC File Name is initially blank. You can either input the path directly, or
you can browse for the specific DBC file. At the end, the DBC File Name field
should contain:
/home/nxuser1/jdevhome/jdev/dbc_files/secure/VX0321.dbc
15. The User Name is FWKTESTER.
16. The Password is FWKDEV.
17. The Application Short Name is AK.
Copyright Oracle Corporation, 2007. All rights reserved.

52

18. The Responsibility Key is FWK_TBX_TUTORIAL.


Note: A full discussion of E-Business Suite security is beyond the scope of this
course. You will learn more about E-Business Suite security later in the course. At
this point, it is enough to know two things. One, these values will work. Two, the
Application Short Name and Responsibility Key could be any value provided that
the User Name being referenced has those values in its definition.
19. Click the OK button.
20. Click the Save All icon, or using the menu choose (Menu) File > Save All, to save
your work.

Copyright Oracle Corporation, 2007. All rights reserved.

53

Task 12: Test Your JDeveloper Set-up


1. Expand the Tutorial project folder.

2. Right-click the test_fwktutorial.jsp file, and choose Run from the context menu.

Copyright Oracle Corporation, 2007. All rights reserved.

54

Note: Ignore any warning messages. Click the OK button on any migration/upgrade
window. The first time any page runs in JDeveloper, it takes longer. Several files
need to be compiled. Numerous files need to be deployed to allow JDeveloper with
OA Extension to operate properly. After the first run, all subsequent test runs will
complete much faster.
3. Click the Hello, World! link.

4. When you see a screen similar to the following, you know that you have correctly
installed JDeveloper 10g with OA Extension, and you have configured it to work
properly with your E-Business Suite instance.

Copyright Oracle Corporation, 2007. All rights reserved.

55

Copyright Oracle Corporation, 2007. All rights reserved.

56

Task 13: Optional Personal Set-up


1. The task that follows is optional, but it will significantly add to your development
productivity. While optional, these changes are strongly recommended.
2. You will be setting up your user account so that when a terminal window is
opened that the JDEV_USER_HOME environment variable is automatically set.
It will also automatically set the E-Business Suite environment. And, it will create
an alias, JDev, which will give you a shorthand means of invoking JDeveloper.
3. Open the terminal window, and input the following commands:
vi .bashrc
i (just press the i key, it will put vi into insert mode)
(Once in insert mode, add these lines)
export JDEV_USER_HOME=/home/nxuser1/jdevhome/jdev
. /appltop/apps/apps_st/appl/VX0321.env
alias JDev=/JDev/jdevbin/jdev/bin/jdev&
(press the Escape key)
(type :wq, and press the Enter key
(This will save your work, and exit vi)

4. Close the terminal window, and reopen a new terminal window. Your
environment will automatically be set, and you can type JDev to start-up
JDeveloper.

Copyright Oracle Corporation, 2007. All rights reserved.

57

Lab 3

Copyright Oracle Corporation, 2007. All rights reserved.

58

Step 1. Setup your environment for OA Framework development


Step 1.1: Create the new workspace.
1.
2.
3.
4.
5.

Select File > New to open the New Gallery.


Select Workspace Configured for Oracle Applications.
Click the OK button.
Set the File Name to ClassLabs.jws.
Confirm that the Directory Name is set to your
JDEV_USER_HOME/myprojects.
Note: This is the default. So, you only need confirm that it is set as expected.

6. Select the Add a New OA Project checkbox.


7. Click the OK button.

Step 1.2: Create the new project.


1. Click the Next button when the Oracle Applications Project Wizard
Welcome page opens.
2. Set the Project Name to ClassProject.
3. Confirm that the Directory Name is set to your
JDEV_USER_HOME/myprojects.
Note: This is the default. So, you only need confirm that it is set as expected.
4. Set the Default Package to oracle.apps.ak.<your name>. Note: You can
use any unique identifier in place of <your name>. It simply assures no
overlap of student files. For example, for demonstration, I will set the Default
Package to oracle.apps.ak.instructor.
5. Click the Next button.
6. At the Database Connection step, Click the Next button to bypass this page.
7. Set the DBC File Name, using the Browse button, to point to the proper DBC
file as directed by your instructor.
8. Click the Next button.
9. Click the Finish button.
10. Click the Save All icon, to save your progress.

Step 1.3: Create (or edit) the database connection.


1. Select the Connections Navigator tab.
2. Right-click the Database folder, and choose New Database Connection.
3. Click the Next button when the Create Database Connection Welcome
page opens.
Copyright Oracle Corporation, 2007. All rights reserved.

59

4. Set the Connection Name to something unique. It is recommended, for


simplicity, that you name the connection the same as the E-Business Suite
database SID which you are using for class.
5. Click the Next button.
6. Set the Username to apps.
7. Set the Password to apps.
8. Click the Next button.
9. Set the Host Name to the information provided by the Instructor or contained
in your DBC file.
Note: You obtained and downloaded your DBC file in the set-up you have
already completed. Your DBC file should not be located in
JDEV_USER_HOME/dbc_files/secure.
10. Set the JDBC Port to the information provided by the Instructor or contained
in your DBC file. Generally, the port is 1521.
11. Set the SID to the information provided by the Instructor or contained in your
DBC file.
12. Click the Next button.
13. Select the Test Connection button.
14. Look for a status of Success!. If you receive a successful test connection,
Click the Next button. If not, check your connection information, and ask your
instructor for assistance.
15. Click the Finish button.
16. Select the Applications Navigator tab.

Step 1.4: Set your projects Run Options.


1. Select the Applications Navigator tab.
2. Double-click ClassProject to open the Project Properties window.
Note: You can also right-click the project, and select Project Properties from
the context window.
3. Expand the Oracle Applications category in the menu panel on the left.
4. Choose Oracle Applications > Run Options.
5. Shuttle OADiagnostics from Available Options to Selected Options using the
> button.
6. Click the OK button.
7. Save your process by selecting the Save All icon.

Copyright Oracle Corporation, 2007. All rights reserved.

60

Step 2. Create the Model-layer Components


Step 2.1: Create your Application Module (AM)
Every OA Framework page has to have a connection to the E-Business Suite database.
The BC4J component that holds the connection and transaction is called an Application
Module.
1.
2.
3.
4.
5.

Right-click the ClassProject project, and choose New from the context menu.
Select Business Tier > ADF Business Components > Application Module.
Click the OK button to open the Create Application Module wizard.
Click the Next button at the Create Application Module Welcome page.
Set the Package to oracle.apps.ak.<your name>.first.server.
Note: Make certain the package name is set properly. Carefully read any
defaults that may have been entered automatically.

6. Set the Name to FirstAM.


7. Click the Next button.
8. Click the Next button. Currently you have not defined any View Objects
(VOs); so, there are no VOs available to add to the AM at this time.
9. Click the Next button. Your AM is not going to reference another AM.
10. Select the Application Module Class: FirstAMImpl, Generate Java File(s)
checkbox.
11. Click the Next button.
12. Click the Finish button.
13. Select the Save All icon.
14. Expand the Application Sources.
15. Expand the oracle.apps.ak.<your name>.first.server package.
16. If you dont see this package in the Applications Navigator, you need to
change the Level display to at least 6.

17. Note that when you expand your oracle.apps.ak.<your name>.first.server, you
will see your newly created FirstAM.

Copyright Oracle Corporation, 2007. All rights reserved.

61

18. Note that the AM created three (3) files noted in the Sources folder of the
Structure panel. Those files are
a. FirstAM.xml the declarative (XML-based) components of the AM.
b. FirstAMImpl.java the programmatic (Java-based) components of the
AM.
c. bc4j.xcfg the XML configuration which lists all the BC4J components
in your project.
19. Save your work.

Step 2.2: Create your Entity Object (EO)


While you only need an Entity Object on an OA Framework page if that page is going to
do an Insert, Update, or Delete, you are going to create an EO for this page as a
building block to future work.
1.
2.
3.
4.
5.
6.

Right-click the ClassProject project, and choose New from the context menu.
Select Business Tier > ADF Business Components > Entity Object.
Click the OK button to open the Create Entity Object wizard.
Click the Next button at the Create Entity Object Welcome page.
Set the Name to FwkTbxAddressesEO.
Set the Package to oracle.apps.ak.<your name>.schema.server.
Note: The default package name is not correct. You will have to enter this
package name manually.

7. In the Schema Object field, type the value, FWK_TBX_ADDRESSES.


Copyright Oracle Corporation, 2007. All rights reserved.

62

Note: If the Database Objects is inactive (grayed out), then you need to reset
your projects database connection. Follow these steps.
a. Select the Cancel button to exit the Create Entity Object wizard.
b. Double-click the ClassProject project to open the Project Properties
windows.
c. Select the Business Components category.
d. In the Connection field, select the drop-down box, and select your
database connection from the list.
e. Select the Edit button to open the Edit Database Connection
window.
f. Select the Test tab.
g. Select the Test Connection button.
h. Test the connect for a Success! status.
i. Click the OK button.
j. Click the OK button.
k. Repeat Steps 1-7. This time the Database Objects should not be
inactive (grayed out).
8. All of FWK_TBX_ADDRESSESs table columns should be listed. If you dont
see the columns, do this.
a. Select the New From Table button.
b. Shuttle all of the columns from Available to Selected using the >>
button.
c. Click the OK button.
9. Click the Next button on Step 2 of 5.
10. Click the Next button on Step 3 of 5.
11. Select the following checkboxes:
a. EOImpl: Generate Java File
b. Accessors
c. Validation Method
d. Create Method
e. Remove Method
12. Click the Next button on Step 4 of 5.
13. Click the Next button on Step 5 of 5.
14. Select the Finish.
15. Note: Are you seeing lots of files in your Applications Sources that arent
yours? If you want to see just your files, here is what you do.
a. Double-click ClassProject to open the Project Properties window.
b. Select the Project Content category.
c. In the Include/Exclude window, you will probably note that it currently
shows (All), and the Include Content Subfolders is checked.
d. Click the Add button in the Included section.
e. In the Add Include Filter, expand oracle > apps, and then select the ak
folder.
f. Click the OK button.
g. Click the OK button.
Copyright Oracle Corporation, 2007. All rights reserved.

63

h. Now you should just see your files in the Applications Navigator.
16. Save your work.

Step 2.3: Create your View Object (VO)


According to Oracle Applications Development standards and just good programming
practice, your VO should include only the attributes (columns) that are going to appear
in the UI. So, you will create a VO, linked to your previously created EO, that includes
just a few of the columns from the table.
1. Right-click the ClassProject project, and choose New from the context menu.
2. Select Business Tier > ADF Business Components > View Object.
3. Click the OK button to open the Create View Object wizard.
4. Click the Next button at the Create View Object Welcome page.
5. Set the Package to oracle.apps.ak.<your name>.first.server.
6. Set the Name to AddressesVO.
7. Select the Rows Populated by a SQL Query with: radio button.
8. Select the Updatable Access through Entity Objects radio button.
9. Click the Next button on Step 1 of 7.
10. Expand the oracle.apps.ak.<your name>.schema.server package.
11. Select the FwkTbxAddressesEO, and shuttle it to the Selected pane.
12. Click the Next button on Step 2 of 7.
13. Select the AddressId, AddressLine1, AddressName, and TownOrCity, and
shuttle them to the Selected pane. Note: It also creates a RowID in the
Selected pane. This is expected behavior. Use the Up and Down arrows in
the Selected pane to order them as AddressId, AddressName, AddressLine1,
TownOrCity, and RowID.
14. Click the Next button on Step 3 of 7.
15. Click the Next button on Step 4 of 7.
16. Click the Next button on Step 5 of 7.
17. Click the Next button on Step 6 of 7.
18. Deselect the AddressesVOImpl: Generate Java File checkbox.
19. Select the AddressesRowVOImpl: Generate Java File and its Accessors
checkboxes. Note: You select these as part of adhereing to Oracle
Applications Development standards that allow extensibility.
20. Click the Next button on Step 7 of 7.
21. Click the Finish button.
22. Save your work.

Step 2.4: Add your VO to your AM


All VOs must be contained within an AM. In this exercise, your AM is FirstAM. You need
to add the EmployeesVO to your FirstAM.
1. Expand Applications Sources > oracle.apps.ak.<your name>.first.server.
2. Double-click FirstAM to open the Application Module Editor.
3. Select the Data Model category (if not already selected by default).
Copyright Oracle Corporation, 2007. All rights reserved.

64

4. Select AddressesVO from the Available View Objects pane, and shuttle it to
the Data Model pane.
5. Notice that when shuttled, AddressesVO becomes AddressesVO1. This is
expected behavior. You are taking the VO from just a definition to a instance
of that definition.
6. While we are in the AM Editor, you need to change one other setting. Select
the Custom Properties category.
7. Set the Name to RETENTION_LEVEL.
8. Set the Value to MANAGE_STATE.
9. Select the Add button to add this custom property.
Note: While not critical at this point, it is part of enabling Passivation on an OA
Framework page. All AMs should be set this way.
10. Click the Apply button.
11. Click the OK button.
12. Save your work.

Step 2.5: Test your BC4J objects


1. Right-click your FirstAM, and choose Test from the context menu.
2. This opens the Oracle Business Component Browser. Select the Connect
button.
3. Double-click the AddressesVO1 in the BC4J browser.
4. This will query the database, and return the records associated with your VO
(which is just a SQL SELECT).
5. You can use the navigation keys in the BC4J browser to explore the records.
6. You can, but you shouldnt, create new Employees. Why shouldnt you?
Because your VO only contains four (4) fields. There is other data that is
required for this table. If you insert a record, you will corrupt the
FWK_TBX_ADDRESSES table.
7. Close the BC4J browser by selecting the [X] at the top of the window.
8. Save your work
To this point, you can only test your progress with the BC4J browser. You have yet to
create any View-layer (UI) components.
To this point, your ClassProject should look as follows:

Copyright Oracle Corporation, 2007. All rights reserved.

65

Copyright Oracle Corporation, 2007. All rights reserved.

66

Step 3. Create the View-layer Components


Step 3.1: Create your page (PG)
1.
2.
3.
4.
5.
6.

Right-click the ClassProject project, and choose New from the context menu.
Select Web Tier > OA Components > Page.
Set the Name to FirstPG.
Set the Package to oracle.apps.ak.<your name>.first.webui
Click the OK button.
FirstPG is created. It is selected in the Applications Navigator panel, and it is
shown in detail in the Structure panel. Additionally, the Property Inspector
opens.

Copyright Oracle Corporation, 2007. All rights reserved.

67

7. In the Structure panel, select region1. Then, using the Property Inspector, set
the following properties for this region.
a. ID: PageLayoutRN
b. AM Definition: Use the () to browse for your FirstAM.
(oracle.apps.ak.<your name>.first.server.FirstAM
c. Window Title: First Page
d. Title: FWK_TBX_ADDRESSES Query
8. Save your work.
9. To test your work, right-click FirstPG.xml in the Applications Navigator or
Structure panel, and choose Run from the context menu. Your page should
appear as follows:

10. While this isnt much, it is your first OA Framework page. Now, lets make it
do something.
Copyright Oracle Corporation, 2007. All rights reserved.

68

Step 3.2: Create your query region


A very common process on OA Framework pages within the E-Business Suite is a
query page. This is so common that a special UI object, the query bean, has been
created to handle this task. A query bean consists of two regions, the query region and
the results table.
1. In the Structure panel, right-click on the PageLayoutRN, and choose New >
Region from the context menu.
2. In the Property Inspector, change the properties of region1 as follows:
a. ID: QueryRN
b. Region Style: query
c. Construction Mode: resultsBasedSearch
d. Include Simple Panel: true
e. Include Views Panel: true
f. Include Advanced Panel: true
3. Save your work.
4. Right-click the QueryRN in the Structure panel, choose New > Region Using
Wizard to open the Create Region wizard.
a. Click the Next button at the Welcome page.
b. Select your FirstAM from the drop-down list of Application Modules.
c. Select your AddressesVO1 in the Available View Usages.
d. Click the Next button.
e. Set the Region ID to ResultsRN.
f. Set the Region Style to table from the drop-down list.
g. Click the Next button.
h. Shuttle all the attributes from Available View Attributes to Selected
View Attributes using the >> button.
i. Click the Next button.
j. Select the Style field for AddressId, and choose messageStyledText
from the drop-down list.
k. In the Step 4 of 4: Region Items table, select the Attribute Set field for
the AddressName attribute. Click the search (flashlight) icon.
l. Select the Browse button for Attribute Set.
m. Select Entire MDS XML Path for the radio button.
n. Select the Browse button.
o. Using the Package Browser, expand down to oracle > apps > fnd >
framework > toolbox > attributesets, and then Click the OK button.
p. Select the Search button. It lists all the associated attribute sets. Note
that some of the attribute sets are named, FwkTbxEmployees, and
have been created specifically for the FwkTbxEmployees table. You
will most likely need to drag-expand the Fully Qualified Name column
to see all the names. Select the
/oracle/apps/fnd/framework/toolbox/attributesets/FwkTbxAddresses/Ad
dressName attribute set.
q. Click the OK button to return.

Copyright Oracle Corporation, 2007. All rights reserved.

69

r. Select the Style field for AddressName, and choose


messageStyledText from the drop-down list.
s. Repeat steps k - r for the AddressLine1 and TownOrCity attributes,
selecting the proper attribute set for each. The values are:
/oracle/apps/fnd/framework/toolbox/attributesets/FwkTbxAddresses/Ad
dressLine1
/oracle/apps/fnd/framework/toolbox/attributesets/FwkTbxAddresses/To
wnOrCity
t. Click the Next button.
u. Click the Finish button to create your results table.
5. Save your work.
6. Select ResultsRN in the Structure panel, and using the Property Inspector,
set the following properties:
a. Additional Text: Addresses Table
b. Width: 100%
c. User Personalization: True
7. Select AddressId in the Structure panel, and using the Property Inspector, set
the following properties:
a. Search Allowed: True
b. Sort Allowed: True
c. Initial Sort Sequence: first
d. Selective Search Criteria: True
e. User Personalization: True
8. Select AddressName in the Structure panel, and using the Property Inspector,
set the following properties:
a. Search Allowed: True
b. Sort Allowed: True
c. Selective Search Criteria: True
d. User Personalization: True
9. Select AddressLine1 in the Structure panel, and using the Property Inspector,
set the following properties:
a. Search Allowed: True
b. User Personalization: True
10. Select TownOrCity in the Structure panel, and using the Property Inspector,
set the following properties:
a. Search Allowed: True
b. Sort Allowed: True
c. User Personalization: True
11. Save your work.
12. Right-click FirstPG.xml in the Applications Navigator or Structure panel, and
choose Run from the context menu. Your page should appear as follows:

Copyright Oracle Corporation, 2007. All rights reserved.

70

13. Explore the page. Note the following


a. You can sort on the AddressId and Name columns by clicking the
column heading.
b. If you click on the column heading a second time, it will change the
sorting from ascending to descending or descending to ascending.
c. Select the Advanced Seach button.

Copyright Oracle Corporation, 2007. All rights reserved.

71

d. Note the Save Search button. This is on the page because we set the
User Personalization property on the ResultRN and its items to True.
e. For advanced challenge, create a User Personalization on your query
page.

Copyright Oracle Corporation, 2007. All rights reserved.

72

This is a powerful technique. You can use this as a template to create a query page for
any table within an E-Business Suite instance, assuming that the E-Business Suite user
and password you are using for your project has the proper access.
Wheres the Controller? The Query Bean encapsulates the controller within the UI
component. There is no need to write an additional controller. This reinforces the notion
from the Basics of the Controller lesson. Only write a controller when you are required
to do so.
Congratulations! You have now completed your first OA Framework page.

Copyright Oracle Corporation, 2007. All rights reserved.

73

Lab 4

Copyright Oracle Corporation, 2007. All rights reserved.

74

Task 1: Create a new responsibility for iExpenses

1. Log into Oracle Applications with user name SYSADMIN and password
SYSADMIN. Your instructor will provide you with the URL to login to the
E-Business Suite instance assigned to your class.
2. Select the System Administrator responsibility.
3. Select Security: Responsibility > Define from the Navigator.
4. Create a new Responsibility with the following values. Replace XXX with your
terminal number as noted above.
Responsibility Name: XXX_iExpenses
Application: Payables
Responsibility Key: XXX_IEXPENSE
Available from radio button: Oracle Self Service Web Applications
Data Group Name: Standard
Data Group Application: Payables

Copyright Oracle Corporation, 2007. All rights reserved.

75

Menu: Expenses Main Menu


Securing Attributes: ICX_HR_PERSON_ID (Oracle iProcurement). Everything
else can be left blank.
Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

76

Task 2: Create a new responsibility for Manager Self Service

1. Create a new Responsibility with the following values.


Responsibility Name: XXX Manager Self Service
Application: Human Resources
Responsibility Key: XXX_MGR_SELFSERVE
Available from radio button: Oracle Self Service Web Applications
Data Group Name: Standard
Data Group Application: Human Resources
Menu: Manager Self Service (Note: No hyphen in Self Service.) Everything else
can be left blank.
Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

77

Task 3: Create a new responsibility for iProcurement


1. Create a new Responsibility with the following values. Replace XXX with your
terminal number as noted above.

Responsibility Name: XXX iProcurement


Application: Oracle iProcurement
Responsibility Key: XXX_IPROCUREMENT
Available from radio button: Oracle Self Service Web Applications
Data Group Name: Standard
Data Group Application: Oracle iProcurement
Menu: Internet Procurement Home
Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

78

Task 4: Create Your User

Create your own username that you will use for most of the following labs. Navigate to
Security: User > Define.
1. Create a new user with the following values.
User Name: XXX_USER
Password: WELCOME (re-enter to verify)
Password Expiration: None
Person: Stock, Ms. Pat (Note: To put this Person into the field, type Stock into
the field, and then press the TAB key. A pop-up will open allowing you to
select Pat Stock. There may be several Pat Stocks in the instance. You need
to select the one that is employee number 24. Accept the error/warning you
get when associating Pat with your new user because this person is
associated with several user names.)
2. Assign the following responsibilities to your user:
Application Developer
Functional Administrator
Copyright Oracle Corporation, 2007. All rights reserved.

79

System Administrator
System Administration
Preferences SSWA
XXX_iExpenses
iExpenses
XXX Manager Self Service
Manager Self Service V3
Sourcing Super User
iProcurement
XXX iProcurement
Customizing Look and Feel Administrator
OA Framework ToolBox Tutorial Labs
OA Framework ToolBox Tutorial
3. Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

80

Task 5: Test your own User


1. Close the form, and return to the Personal Home Page.
2. Click the Logout link at the top of the Personal Home Page.
3. Return to the login page.

4. Use your new login and password (WELCOME) to log in again. You will be
prompted to change your password.

5. Your new password is:

_________________________________

6. Verify that you have the correct Responsibilities displayed.

Copyright Oracle Corporation, 2007. All rights reserved.

81

Copyright Oracle Corporation, 2007. All rights reserved.

82

Task 6: Set Profile Options


Before you can do administrator-level personalizations such as seeding user views,
adding items, and so on, you need to set three profile options. There are two ways you
can set system profile option values: the Profiles page in the Functional Administrator
responsibility and the System Profiles form in the System Administrator responsibility.
1. Select the Functional Administrator responsibility.
2. Navigate to the Core Services tab, and the Profiles subtab.
3. There are three profile options to set.
Profile Name
Personalize Self-Service Defn
FND: Personalization Region Link Enabled
FND: Diagnostics

Value
Yes
Yes
Yes

4. Query the Personalize Self-Service Defn profile option for your user.

Copyright Oracle Corporation, 2007. All rights reserved.

83

5. Select the Update Value icon or the Define Profile Values button.
6. Initially, you come to the profile value at the Site level. You are not going to
change the Site value. You are going to change the User level. So, select the
User tab.

Copyright Oracle Corporation, 2007. All rights reserved.

84

7. Your user is not yet defined. So, you will need to add it. Select the Add Another
Row button.
8. Type your user, XXX_USER, into the User field, and assign it the value of Yes.
9. Select the Update button to save your setting.
10. Repeat steps 4 9 for the FND: Diagnostics and FND: Personalization Region
Link Enabled profile options.
11. When you are complete, return to the Home Page. Your new Home Page should
look similar to the following:

Copyright Oracle Corporation, 2007. All rights reserved.

85

This appears on the page due to the Personalize Self-Service Defn profile option.

These appear on the page due to the FND: Diagnostics profile option.

Copyright Oracle Corporation, 2007. All rights reserved.

86

These appear on the page due to the FND: Personalization Region Link Enabled profile
option.

Copyright Oracle Corporation, 2007. All rights reserved.

87

Task 7: Learn the Administrator-level Personalization UI


From here on, you will do administrator-level personalizations.
1. Select your XXX_iExpenses responsibility.
2. Select the Expense Reports subtab.

Copyright Oracle Corporation, 2007. All rights reserved.

88

3. Select the Personalize Page link at the top of the page.

4. Examine the Personalization hierarchy page.

Note the context of your personalization.

View the hierarchy in Simple mode. Note that some Reorder and Create
Item icons are disabled (grayed out).

View the hierarchy in Complete mode. Note that the Reorder and Create
Item icons are now enabled.

Select Expand All to see the entire region and item hierarchy of the Expense
Reports page.

Copyright Oracle Corporation, 2007. All rights reserved.

89

Task 8: Create Administrator-seeded User-level Personalizations


1. Still within the Administrator Personalization UI, scroll down the Personalization
Structure until you find the Advanced Table: List of expense r... region inside
the QueryRN region.

2. Select the Seeded User Views icon (eyeglasses) to go to the Personalize Views
page.

3. Select the Create View button to go to the Create View page.


4. Set the View Name to XXX Admin: Paid Expense reports 2002-2003.
5. Set the Number of Rows Displayed to 20 Rows.

Copyright Oracle Corporation, 2007. All rights reserved.

90

6. Remove the Name, Report Submit Date, and Due Date columns.

7. Set the query criteria to have the Report Date to after 31-Dec-2001.
8. Add another criteria field by setting the Add Another field to Report Date, and
clicking the Add button.
9. Set the new query criteria to have the Report Date to before 01-Jan-2004.
10. Add another criteria field by setting the Add Another field to Report Status, and
clicking the Add button.

Copyright Oracle Corporation, 2007. All rights reserved.

91

11. Select the Show table data when all conditions are met radio button.
12. Set the new query criteria to have the Report Status of Paid.

13. Click the Apply button to return to Personalize Views page.

14. Click the Apply to return to Personalize Page: Expense Reports.


15. Click the Return to Application link to return to the Expense Reports page.
16. Click the Views button to get to the Views page, select your new view from the
poplist, and select Go. You should see results similar to the following:
Copyright Oracle Corporation, 2007. All rights reserved.

92

Copyright Oracle Corporation, 2007. All rights reserved.

93

Task 9: Test Your Administrator-seeded Personalizations


1. Select the Home link at the top of the page.
2. Select iExpenses responsibility. (Note: This is the original iExpenses
responsibility, not your new XXX_iExpenses responsibility.)
3. Navigate to the Expense Reports subtab.
4. Select the Views button.
5. Verify that all three views are still available from the poplist.
6. Select the Logout link at the top of the page.
7. Login as MFG with password WELCOME.
8. Select the iExpenses responsibility.
9. Navigate to the Expense Reports subtab.
10. Select the Views button.
11. You should only see your Administrator-seeded User-level Personalizations. You
will not see the user-level personalizations you created for your XXX_USER
user.
12. Select the Logout link at the top of the page.
13. Login as your XXX_USER user.

Copyright Oracle Corporation, 2007. All rights reserved.

94

Task 10: Add a Tip to a Page


In this task you will add a tip to the bottom of a page. Tips are useful for adding extra
information specific to your user community. Tips can be added to any region in the
page.
1. Login using your own username, if you arent already login in that way.
2. Select your XXX_iExpenses responsibility.
3. Stay on the Expenses Home subtab. Do not go the Expense Reports subtab.
4. Select the Personalize Page link in the upper right corner of the screen.
5. Select the Complete View radio button in the Personalization Structure region.
6. Select the Create Item icon on the Page Layout: Expenses Home row in the
Personalization Structure region.
7. Check that the Level is set to Function: OIE Home Page.
8. Change the Item Style of your new item to Tip.
9. Set the ID property to XXX_Tip.
10. Set the Text property to XXX This is a new tip.

Copyright Oracle Corporation, 2007. All rights reserved.

95

11. Select Apply button to return to the Personalization Structure page.


12. Select the Return to Application link.

13. Select the Personalize Page link.


14. Select the Personalize icon (not the Update Item icon) for your new tip. (Tip:
XXX This is a new tip).
15. Personalize your new tip so that it is rendered only at the responsibility level for
your responsibility. Use the Choose Levels Displayed button to display only the
Function level and the Responsibility level. Select the Apply button when
complete.

16. Note: Selecting and reducing the number of levels, with the Choose Levels
Displayed button, is one of the most important steps you can take to avoid
problems in implementing personalizations. Otherwise, the UI can be too
crowded to avoid unintendedly typing something into the wrong property at the
wrong level.

Copyright Oracle Corporation, 2007. All rights reserved.

96

17. Set the Rendered property to false at the Function level and to true at the
Responsibility level.
18. Click the Apply button.
19. Click the Return to Application link.
20. Verify that you can see the tip on your page.
21. Click the Home link on the top of the page.
22. Select the iExpenses responsibility.
23. Verify that your tip does not appear in this responsibility. If your tip appears,
repeat steps 14 21 XXX_iExpenses responsibility.

Copyright Oracle Corporation, 2007. All rights reserved.

97

Task 11: Add Button links


In this task you will add a button to the bottom of a page. Buttons are useful for
providing a link to a destination such as a different page or another web site. Buttons
can be added to any region in the page, though some region styles, such as Default
Single Column, may control the placement of the button within the region.
1. Select to your XXX_iExpenses responsibility from the Personal Home Page.
2. Select the Personalize Page link.
3. Select the Complete View.
4. Create a new item on the Page Layout: Expenses Home row in the
Personalization Structure region.
5. Change the Item Style of your new item to Button.
6. Set the ID to XXX_Button.
7. Set the Destination URI to http://education.oracle.com.
8. Set the Prompt to XXX Oracle Education.
9. Select the Apply button.
10. Select the Return to Application link.

11. Select the Personalize Page link.


12. Select the Personalize icon (not the Update Item icon) for your new button.

Copyright Oracle Corporation, 2007. All rights reserved.

98

13. Personalize your new tip so that it is rendered only at the responsibility level for
your responsibility. Use the Choose Levels Displayed button to display only the
Function level and the Responsibility level.
14. Note: Selecting and reducing the number of levels, with the Choose Levels
Displayed button, is one of the most important steps you can take to avoid
problems in implementing personalizations. Otherwise, the UI can be too
crowded to ensure avoiding unintendedly typing something into the wrong
properly at the wrong level.
15. Set the Rendered property to false at the Function level and to true at the
Responsibility level.
16. Click the Apply button.
17. Click the Return to Application link.
18. Verify that you can see the button on your page.
19. Click the Home link on the top of the page.
20. Select the iExpenses responsibility.
21. Verify that your button does not appear in this responsibility. If your button
appears, repeat steps 12 19 on your XXX_iExpenses responsibility.

Copyright Oracle Corporation, 2007. All rights reserved.

99

Task 12: Rearrange the Regions on a Page


In this task you will rearrange the regions on the Expenses Home page.
1. Select your XXX_iExpenses responsibility from the Personal Home Page.
2. Click the Personalize Page link.
3. Choose the Complete View.
4. Select the Reorder icon next in the Default Single Column row of the
Personalization Structure table.
5. Check the check box for Personalize in the Responsibility region of the Reorder
Contents page.
6. Highlight Notifications in the Responsibility region and use the arrows to move
Notifications to the top of the region.

7. Select the Apply button.

Copyright Oracle Corporation, 2007. All rights reserved.

100

8. Select the Return to Application link.


9. The Notifications region is now first on the page.

Copyright Oracle Corporation, 2007. All rights reserved.

101

Task 13: Add a Column to a Table - Analysis


In this task you will add a column to the Track Submitted Expense Reports region on
the Expenses Home page. The column is included in the underlying view object (data
source) for this region, but is not currently displayed in the table on the page. The first
thing you need to do is determine what column to add to the table.
1. Select your XXX_iExpenses responsibility from the Personal Home Page.
2. Look at the Track Submitted Expense Reports region and note what columns
are in the table.
3. Select About this Page at the bottom of the page to view the details this page.
4. In the Page Definitions region, choose the Expand All link.
5. Note the view object (VO) name, TrackExpenseReportsVO, for the Track
Submitted Expense Reports region in the first table of About this Page. You
will need the exact name, including case, later in this lab.

Copyright Oracle Corporation, 2007. All rights reserved.

102

6. Show the Business Component References Details just below the Page
Definition table.
7. Scroll down to the View Objects table and find the information for the
TrackExpenseReportsVO. Select the link.

8. Scroll down past the query to the Attributes table, and determine what column
you would like to add to the table. For this task we will add CurrencyCode to
the table. Note the exact attribute name including case, as we will need it later in
this lab.

Copyright Oracle Corporation, 2007. All rights reserved.

103

9. Select the Return to About Page link in the lower left corner of the screen.
10. Select Return to Page: Expenses Home link.

Copyright Oracle Corporation, 2007. All rights reserved.

104

Task 14: Add Column to the Table


Now that you know what column to add to the Track Submitted Expense Report
Region, use personalization to add the column.
1. Select the Personalize Track Submitted Expense Reports link to enter the
personalization pages.
2. You do not need to choose the Complete View, it is chosen by default.
3. Select the Create Item icon in the Table: Track Submitted E row.
4. Select Message Styled Text from the list for Item Style.
5. Set the ID property to XXX_CurrCode.
6. Set the Prompt property to XXX Currency Code.
7. Set the View Attribute property to CurrencyCode.
8. Set the View Instance property to TrackExpenseReportsVO.
9. Select the Apply button.
10. You will return to the Personalization Structure, and see XXX Currency Code
added. (Note: You may have to return to the application to see the population of
the item.)
11. Now make your new column visible only from your own responsibility. Select the
Personalize icon (not the Update Item icon) for your new item.
12. Select the Choose Levels Displayed button.
13. Select just the Function and Responsibility levels to be displayed.
14. Click the Apply button.
15. Set the Rendered property to false at the Function level and true at the
Responsibility level.
16. Click the Apply button.
17. Select the Return to Application link.

Copyright Oracle Corporation, 2007. All rights reserved.

105

18. Verify that the new XXX Currency Code is in your table.
19. Return to the Personal Home Page, switch responsibilities to the iExpenses
responsibility, and return to the Expenses Home page. Verify that your XXX
Currency Code column does not appear in the iExpenses responsibility.
20. Return to your XXX_iExpenses responsibility.

Copyright Oracle Corporation, 2007. All rights reserved.

106

Task 15: Reorder Table Columns


In this task you will reorder the columns to put XXX Currency Code to the right of
Report Total in the table.
1. Return to the Home Page, and select your XXX_iExpenses responsibility.
2. Select the Personalize Track Submitted Expense Reports link to enter the
personalization pages.
3. Select the Reorder icon in the Table: Track Submitted E table row of the
Personalization Structure table.
4. Uncheck the checkbox for Personalize in the Function level of the Reorder
Contents page.
5. Check the checkbox for Personalize in the Responsibility region of the
Reorder Contents page.
6. Highlight XXX Currency Code in the Responsibility region. Use the arrows to
move XXX Currency Code to just below Report Total. (Note: There are two (2)
report column fields. Be certain to move it below the second field.)
7. Select the Apply button.
8. Select the Return to Application link.
9. Verify the new order of the XXX Currency Code field in the region.

Copyright Oracle Corporation, 2007. All rights reserved.

107

Task 16: Personalize Privacy Link Globally Across Pages


In this task you will personalize the Privacy link for all pages, changing both its text and
the link to which it points.
1. Select your XXX_iExpenses responsibility from the Personal Home Page.
2. Select the Personalize Page link.
3. Select the Choose Context button.
4. Select Shared Region: Privacy Statement from the Scope poplist.

5. Select the Apply button.


6. Select the Personalize icon for the Link: Privacy Statement item.
7. Select the Choose Levels Displayed button.
8. Select only the Responsibility level to be displayed.
9. Click the Apply button.
10. Set the Text property to XXX Privacy Statement.
11. Set the Destination URI to http://www.oracle.com/html/privacy.html.
12. Click the Apply button.
13. Select the Return to Application link.

Copyright Oracle Corporation, 2007. All rights reserved.

108

14. Verify that your privacy statement is now personalized, but only for your
responsibility. Switch to another responsibility and check the Privacy links.

Copyright Oracle Corporation, 2007. All rights reserved.

109

Task 17: Disable Your Personalizations


Now that you have created personalizations in the Expenses Home page, lets disable
them temporarily. Why? A common situation might be the personalizations have caused
unwanted side effects, so you deactivate the personalizations for debugging.
1. Select your XXX_iExpenses responsibility from the Personal Home Page.
2. Select the Personalize Page link.
3. Select the Manage Levels button to enter the Manage Personalization Levels
page.
4. Select the responsibility-level personalizations that you created (check the

appropriate checkbox), and select the Deactivate button to disable the


personalization. You have to do this region by region. You cannot select all your
personalizations at one time, and simply select one Deactivate button. Ensure
your designation appears in the Value column for any personalization you
disable. Do not disable function-level personalizations.
Tip: be sure to check the date the personalization was created to help you
distinguish your new personalizations from any previous personalizations.
Note: You cannot deactivate personalizations against shared regions, like the privacy
statement.

5. Select the Return to Personalization Structure link.


6. Select the Return to Application link.

Copyright Oracle Corporation, 2007. All rights reserved.

110

7. All your responsibility-level personalizations should be inactive. At the function


level, the personalizations are still active, but the new fields should all be set so
that they are not rendered. The page should, visually at least, be back to its
original starting appearance.

Copyright Oracle Corporation, 2007. All rights reserved.

111

Task 18: Using the Functional Administrator


Now that you have deactivated your Expenses Home responsibility-level
personalizations, this task will use the Functional Administrator Responsibility to search
for and delete those personalizations permanently.
1. Select the Functional Administrator responsibility from the Personal Home
Page.
2. Select the Personalization tab.
3. On the Application Catalog subtab, select the Payables application, check the
Personalized check box, and select Go.
4. Locate the line: Payables /oracle/apps/ap/oie/webui/HomePG and select the
Manage Personalizations icon.

5. Check the checkbox of the responsibility-level personalization for your


XXX_iExpenses responsibility and select the Delete Personalizations button.
You must do this for each region where you have personalizations you want to
delete. This is the same manner as you did to deactivate those personalizations.

Copyright Oracle Corporation, 2007. All rights reserved.

112

6. Before it lets you delete a personalization, it checks ones last time to ensure that
you intend to delete. Select the Yes button to continue with the deletion.

7. Select the Return to Application Catalog Page link.


8. Select Home to return to the Personal Home Page.

Copyright Oracle Corporation, 2007. All rights reserved.

113

Task 19: Make a Field Required


On the Hire Employee page in the XXX Manager Self Service responsibility, Date of
Birth is not currently required, but your company requires it. Personalize the page so
that the Date of Birth is required for your XXX Manager Self Service responsibility but
not for other responsibilities.
1. Select your XXX Manager Self Service responsibility from the Personal Home
Page.
2. Select the Hire page.

3. Select the Personalize Page link.


4. Enter Date of Birth in the Title/Prompt/Text field in the Search region, and click
Go.
5. Select the Personalize icon.
6. Select the Choose Levels Displayed button.
7. Select only the Responsibility level to be displayed.
8. Click the Apply button.
9. Set the Required property to yes at the Responsibility level.
10. Click the Apply button.
11. Select the Return to Application link.
Copyright Oracle Corporation, 2007. All rights reserved.

114

12. Verify that the Date of Birth field is required.

Copyright Oracle Corporation, 2007. All rights reserved.

115

Lab 5

Copyright Oracle Corporation, 2007. All rights reserved.

116

Task 1: Determine Which Flexfield to Set-Up


In this task you want to set-up the descriptive flexfield in the Unprocessed Requests
page in Oracle Sourcing. You will also set-up segments for the flexfield.
1. Log in as your XXX_USER.
2. Select the iProcurement responsibility.
3. Select the Non-Catalog Request subtab.

Copyright Oracle Corporation, 2007. All rights reserved.

117

4. Select the About this Page link to determine if there is a flexfield available on
this page, and note its name and application short name. In our case, the
Application Short Name is PO, and the flexfield name is
PO_REQUISITION_LINES.

5. Select the Return to Page: Unprocessed Requests link.

Copyright Oracle Corporation, 2007. All rights reserved.

118

Task 2: Define Descriptive Flexfield Segments


1. Go to the Home page and switch to the Application Developer responsibility.
2. Navigate to the Descriptive Flexfield Register form, Flexfield: Descriptive >
Register
3. Query the Name field using PO_REQUISITION_LINES. Note that the Title of this
flexfield is Requisition Lines. You will need that name to set-up the segments.

4. Close the Descriptive Flexfield Register form, and open the Descriptive
Flexfield Segments form, (N) Flexfields > Descriptive > Segments.
5. Query the Descriptive Flexfield Segments by Title using Requisition Lines.

Copyright Oracle Corporation, 2007. All rights reserved.

119

6. Unfreeze the flexfield by deselecting the Freeze Flexfield Definition checkbox.


7. Select OK for the warning message.

Copyright Oracle Corporation, 2007. All rights reserved.

120

8. Select the Global Data Elements code, and then click the Segments button.

9. Set the Number to 10.


10. Set the Name to Priority.
11. Set Column to ATTRIBUTE1.
12. Set the Value Set to Priority
13. Tab to the next row.

Copyright Oracle Corporation, 2007. All rights reserved.

121

14. Click OK on the Caution dialog box that opens.

15. Set the Number to 20.


16. Set the Name to Justification.
17. Set Column to ATTRIBUTE2.
18. Tab to the next row.
19. Click OK on the Caution dialog box that opens.
20. Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

122

21. Close the Descriptive Flexfield Segments windows, back to the main form.
22. Check the Freeze Flexfield Definition checkbox.
23. Select OK for the warning message.

24. Save your work again to compile the flexfield.

25. When the flexfield is compiled successfully, you will get a Note window to notify
you.

Copyright Oracle Corporation, 2007. All rights reserved.

123

Copyright Oracle Corporation, 2007. All rights reserved.

124

Task 3: Enable Descriptive Flexfield on Page


1. Exit the forms-based Applications, and return to the Personal Home Page.
2. Select the iProcurement responsibility.
3. Select the Non-Catalog Request subtab.
4. Select Personalize Page.
5. Select Complete View.
6. Select the Flexs Personalize icon, and set the Rendered property at the Site
level to true.
7. Select the Labeled Field Layout: (ReqLineDffLabel) personalize icon, and set
the Rendered property at the Site level to true.
8. Select the Header: Additional Information personalize icon, and set the
Rendered property at the Site level to true.
9. Note: You MUST do this separately for the Flex, the Field Layout and the Header
(which are the Flexs container) in order to enable the descriptive flexfield.

10. Apply your changes, and Return to the Application.

Copyright Oracle Corporation, 2007. All rights reserved.

125

11. You should see the two flexfield columns appearing at the end of the page in the
Additional Information region.

Note:: There is one technique of interest to both instructors and students. Often
times when dealing with OA Framework pages, there are interesting quirks that
might or might not appear. Things like menu items not appearing, responsibilities not
appearing, and the like. Why? Because Oracle Application Framework has a cache
of run-time information, and by default that cache only gets reloaded every 15
minutes. So, here is the technique to clear the cache quicker.
1. From the SYSADMIN user, or any user in the Application that has the
Functional Administrator responsibility, choose the Functional Administrator
responsibility from the Personal Home Page.
2. Choose the Core Service tab.
3. Choose the Caching Framework subtab.

Copyright Oracle Corporation, 2007. All rights reserved.

126

4. Choose the Global Configuration submenu.

5. Choose the Clear All Cache button.


6. Click the Yes button at the Warning page.

If the problem was due to an Oracle Application Framework caching problem, you
have now flushed the cache. Any item now required will be loaded on demand
because it is no longer in the cache. Your quirk should go away.

Copyright Oracle Corporation, 2007. All rights reserved.

127

Task 4: Create a new flexfield on the Non-Catalog Request Page


This task requires that the Requisition Lines descriptive flexfield has already had its
segments defined and that the flexfield is frozen.
1. Login to the Application as your XXX_USER.
2. Select the XXX iProcurement responsibility.
3. Select the Non-Catalog Request subtab.
4. Select the Personalize Page link.
5. Select the Complete View.
6. Select the Create Item icon for the Page Layout: Oracle iProcurement: Shop
region.
7. Set the Level to Site.
8. Set the Item Style to Stack Layout.
9. Set the ID to XXX_StackLayout.
10. Set the Prompt to XXX Additional Information.
11. Select the Apply button.
12. You should see your new XXX Additional Information in the Personalization
Structure.
13. Select the Create Icon on the XXX_StackLayout item.
14. Set the Level to Site.
15. Set the Item Style to Static Styled Text.
16. Set the ID to XXX_FlexText.
17. Set the CSS Class to OraInstructionTextStrong
18. Set the Prompt to XXX Lines Flexfield.
19. Select the Apply button.
20. You should see your new XXX Lines Flexfield in the Personalization Structure.
21. Select the Create Icon on the XXX_StackLayout item.
Copyright Oracle Corporation, 2007. All rights reserved.

128

22. Set the Level to Site.


23. Set the Item Style to Flex.
24. Set the ID to XXX_ReqLinesFlex.
25. Set the Appl Short Name to PO.
26. Set the Display Context Field to false.
27. Set the Name to PO_REQUISITION_LINES.
28. Set the Prompt to XXX Lines.
29. Set the Type to descriptive.
30. Set the View Instance to NonCatalogRequestVO.
31. Select the Apply button.
32. Select the Return to Application link.

Copyright Oracle Corporation, 2007. All rights reserved.

129

33. Verify that your personalization is in effect.

Copyright Oracle Corporation, 2007. All rights reserved.

130

Copyright Oracle Corporation, 2007. All rights reserved.

131

Task 5: Make Your Flexfield Visible to Your Responsibility


1. Select the Personalize Page link.
2. Select Complete View
3. Select the Personalize icon (not the Update Item icon) for your new Stack
Layout. If you personalize just the flexfield, the Static Style Text boilerplate will
still appear.
4. Select the Choose Levels Displayed button.
5. Select just the Site and Responsibility levels to display.
6. Select the Apply button.
7. Set the Rendered property to false at the Site level, and to true at the
Responsibility level.
8. Select the Apply button.
9. Select the Return to Application link.
10. Verify that the flexfield is only visible for your responsibility. From the Personal
Home Page, choose the iProcurement responsibility, then the Non-Catalog
Request subtab, to confirm.

Copyright Oracle Corporation, 2007. All rights reserved.

132

Lab 6

Copyright Oracle Corporation, 2007. All rights reserved.

133

Task 1: Set-up SQLDeveloper


1. On your classroom desktop, double-click the SQLDeveloper icon.

2. Allow SQLDeveloper to start-up.

3. Create a connection to your E-Business Suite database


a. Right-click Connections, choose New Connection.

b. Set your Connection Name as desired.


c. Set the Username to apps.
d. Set the Password to apps.

Copyright Oracle Corporation, 2007. All rights reserved.

134

e. Set the Hostname to your E-Business Suite hostname.


f. Set the SID to your E-Business Suite SID

g. Click the Test button. Make sure the Status: shows as Success. If not, check
your settings (above), and repeat until Success is shown.
h. Click the Save button.

Copyright Oracle Corporation, 2007. All rights reserved.

135

i.

Click the Connect button.

Copyright Oracle Corporation, 2007. All rights reserved.

136

Task 2: Navigate Around the Database


Answer the following questions about the E-Business Database that you are using.
Solutions are provided in the Solution section at the end of the lab.
1. Run the following SQL Statement
SELECT COUNT(*)
FROM sys.dba_objects
WHERE UPPER(object_name) NOT LIKE 'BIN$%'
2. How many objects are in your E-Business Suite database?
_________________________
3. Run the following SQL Statement
SELECT object_type "Object Type",
COUNT(*) "Object Count"
FROM sys.dba_objects
WHERE UPPER(object_name) NOT LIKE 'BIN$%'
GROUP BY object_type
ORDER BY 1
4. How many tables are in your E-Business Suite database?
_________________________
5. Expand the Connection (for example, VX0321).
6. View the Table of your choice.
7. Open the Packages folder.
8. View the JDR_UTILS package.
9. What is the name of one (1) procedure in the JDR_UTILS package?
_________________________

Copyright Oracle Corporation, 2007. All rights reserved.

137

10. What is the name of one (1) function in the JDR_UTILS package?
_________________________
11. Open the Tables folder.
12. Run the following SQL Statement
SELECT USER_NAME
FROM FND_USER
13. Find the FND_USER table in the Tables folder that you opened in Step 11.
14. Why is the table not listed?
______________________________________________________________
______________________________________________________________
______________________________________________________________
______________________________________________________________
______________________________________________________________
______________________________________________________________
15. Open the Other Users folder.
16. Select the APPLSYS user.
17. Select the Table folder under the APPLSYS user.
18. How many columns are in the FND_USER table?
_________________________

Copyright Oracle Corporation, 2007. All rights reserved.

138

Task 3: Administer the Database


1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the oracle user. The oracle user password is oracle.
5. Navigate to the ORACLE_HOME directory (/app/db_st/10.2.0.2).
6. Run the database ORACLE_HOME environment file for your E-Business Suite
instance.
7. Navigate to the database ORACLE_HOME/appsutil/scripts/<context
name> directory.
8. List the files in this directory.
9. Stop the database using the addbctl.sh script.
The file header for each script contains instructions on how to run the script.
10. Restart the database.
11. Examine the format of the Net Services listener process script and, if time
permits, use it to stop and start the listener.

Copyright Oracle Corporation, 2007. All rights reserved.

139

Solution Task 2
1. Run the following SQL Statement
SELECT COUNT(*)
FROM sys.dba_objects
WHERE UPPER(object_name) NOT LIKE 'BIN$%'
2. How many objects are in your E-Business Suite database?
Approximately 364,909 (this will vary depending upon the patches that have been
applied to an E-Business Suite instance.)
3. Run the following SQL Statement
SELECT object_type "Object Type",
COUNT(*) "Object Count"
FROM sys.dba_objects
WHERE UPPER(object_name) NOT LIKE 'BIN$%'
GROUP BY object_type
ORDER BY 1
4. How many tables are in your E-Business Suite database?
Approximately 32,426
5. Expand the Connection (for example, VX0321).
6. View the Table of your choice.
7. Open the Packages folder.
8. View the JDR_UTILS package.
9. What is the name of one (1) procedure in the JDR_UTILS package?
deleteDocument, deleteEmptyCustomizations, deletePackage, listContents,
listCustomizations, listDocuments, listLanguages, printDocument,
printTranslations, saveTranslations

Copyright Oracle Corporation, 2007. All rights reserved.

140

10. What is the name of one (1) function in the JDR_UTILS package?
exportDocument, getComponentName, getDocumentName, getTranslations
11. Open the Tables folder.
12. Run the following SQL Statement
SELECT USER_NAME
FROM FND_USER
13. Find the FND_USER table in the Tables folder that you opened in Step 11.
14. Why is the table not listed?
It is not there because you are logged in to the database as APPS. The
FND_USER table is owned by APPLSYS. The reason that you can see it
as the APPS user is because a synonym exists in the APPS schema to the
APPLSYS object.
15. Open the Other Users folder.
16. Select the APPLSYS user.
17. Select the Table folder under the APPLSYS user.
18. How many columns are in the FND_USER table?
28 columns

Copyright Oracle Corporation, 2007. All rights reserved.

141

Solution Task 3
1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the oracle user. The oracle user password is oracle.
su - oracle
5. Navigate to the ORACLE_HOME directory (/app/db_st/10.2.0.2).
cd /app/db_st/10.2.0.2
6. Run the database ORACLE_HOME environment file for your E-Business Suite
instance.
. VX0321_vx0321.env
Note: The above command will change based on the server and SID that you
have been assigned. The above command assumes that you have been
assigned the VX0321 SID on the vx0321 server.
7. Navigate to the database ORACLE_HOME/appsutil/scripts/<context
name> directory.
cd $ORACLE_HOME/appsutil/scripts/VX0321_vx0321
Note: The above command will change based on the server and SID that you
have been assigned. The above command assumes that you have been
assigned the VX0321 SID on the vx0321 server.
8. List the files in this directory.
ls
Note: You should see the following scripts/files listed in the directory.
adautocfg.sh
adddbctl.sh
adexecsql.sh
adpreclone.pl

Copyright Oracle Corporation, 2007. All rights reserved.

142

adstrtdb.sql
adchknls.pl
addlnctl.sh
adlsnodes.sh
adstopdb.sql
9. Stop the database using the addbctl.sh script.
The file header for each script contains instructions on how to run the script.
. addbctl.sh stop immediate
10. Restart the database.
. addbctl.sh start
11. Examine the format of the Net Services listener process script and, if time
permits, use it to stop and start the listener.
. addlnctl.sh status VX0321
. addlnctl.sh stop VX0321
. addlnctl.sh start VX0321
Note: The above commands will change based on the SID that you have been
assigned. The above command assumes that you have been assigned the
VX0321 SID.

Copyright Oracle Corporation, 2007. All rights reserved.

143

Lab 7

Copyright Oracle Corporation, 2007. All rights reserved.

144

Task Navigate the File System


1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the applmgr user. The oracle user password is applmgr.
5. Navigate to the APPL_TOP directory (/appltop/apps/apps_st/appl).
6. Run the consolidated environment file for your E-Business Suite instance.
7. List the directories and files in this directory (APPL_TOP).
8. Review the directory structure for a product. All Oracle Applications products
share virtually the same directory structure.
9. Navigate to COMMON_TOP.
10. Review the contents of COMMON_TOP.
11. Display the full path to COMMON_TOP.
12. Navigate to INST_TOP.
13. Review the contents of INST_TOP.
14. Navigate to JAVA_TOP and review the contents.
15. Navigate to the tools ORACLE_HOME, and display the full path to the directory.
This is the OracleAS ORACLE_HOME for the Oracle Developer products.

Copyright Oracle Corporation, 2007. All rights reserved.

145

Solution - Navigate the File System


1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the applmgr user. The oracle user password is applmgr.
su - applmgr
5. Navigate to the APPL_TOP directory (/appltop/apps/apps_st/appl).
cd /appltop/apps/apps_st/appl
6. Run the consolidated environment file for your E-Business Suite instance.
. APPSVX0321_vx0321.env
Note: The above command will change based on the server and SID that you
have been assigned. The above command assumes that you have been
assigned the VX0321 SID on the vx0321 server.
7. List the directories and files in this directory (APPL_TOP).
ls
8. Review the directory structure for a product. All Oracle Applications products
share virtually the same directory structure.
cd $GL_TOP
ls
Note: You could have picked another product. The example assumes you picked
the GL product top to review.
9. Navigate to COMMON_TOP.
cd $COMMON_TOP
10. Display the full path to COMMON_TOP.
pwd
11. Review the contents of COMMON_TOP.
ls
Copyright Oracle Corporation, 2007. All rights reserved.

146

12. Navigate to INST_TOP.


cd $INST_TOP
13. Review the contents of INST_TOP.
ls
14. Navigate to JAVA_TOP and review the contents.
cd $JAVA_TOP
ls
15. Navigate to the tools ORACLE_HOME, and display the full path to the directory.
cd $ORACLE_HOME
pwd

Copyright Oracle Corporation, 2007. All rights reserved.

147

Lab 8

Copyright Oracle Corporation, 2007. All rights reserved.

148

Task Administering the Server Processes


1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the applmgr user. The oracle user password is applmgr.
5. Navigate to the APPL_TOP directory (/appltop/apps/apps_st/appl).
6. Run the consolidated environment file for your E-Business Suite instance.
7. Navigate to INST_TOP/admin/scripts directory and review the files in this
directory.
8. Stop the Concurrent Processing server process.
The file header for each script contains instructions on how to run the script. You
will find that there are file headers that do not specify whether or not to pass the
APPS user and password to start or stop that specific process. If the APPS
user/password must be passed during the command, a message or prompt will
indicate that when you attempt to run the command. The APPS password is apps
for your classroom E-Business Suite instances.
9. Start the Concurrent Processing server process.
10. Stop all application tier server processes.
11. Attempt to access the Oracle Applications Login Page. What happens?
12. Start all the application tier server processes.
13. Examine the other server process scripts and, if time permits, use them to stop
and start the various application tier server processes.

Copyright Oracle Corporation, 2007. All rights reserved.

149

Solution Administering the Server Processes


1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the applmgr user. The oracle user password is applmgr.
su - applmgr
5. Navigate to the APPL_TOP directory (/appltop/apps/apps_st/appl).
cd /appltop/apps/apps_st/appl
6. Run the consolidated environment file for your E-Business Suite instance.
. APPSVX0321_vx0321.env
Note: The above command will change based on the server and SID that you
have been assigned. The above command assumes that you have been
assigned the VX0321 SID on the vx0321 server.
7. Navigate to INST_TOP/admin/scripts directory and review the files in this
directory.
cd $INST_TOP/admin/scripts
ls
8. Stop the Concurrent Processing server process.
The file header for each script contains instructions on how to run the script.
adcmctl.sh stop apps/apps
9. Start the Concurrent Processing server process.
adcmctl.sh start apps/apps
10. Stop all application tier server processes.
adstpall.sh apps/apps
11. Attempt to access the Oracle Applications Login Page. What happens?
You will receive an error message because the browser is unable to connect to a
web service that is not currently running.
Copyright Oracle Corporation, 2007. All rights reserved.

150

12. Start all the application tier server processes.


adstrtal.sh apps/apps
13. Examine the other server process scripts and, if time permits, use them to stop
and start the various application tier server processes.
The additional control scripts are:
adalnctl.sh
adapcctl.sh
adautocfg.sh
adformsctl.sh
adformsrvctl.sh
adoacorectl.sh
adoafmctl.sh
adopmnctl.sh
gsmstart.sh
jtffmctl.sh

Copyright Oracle Corporation, 2007. All rights reserved.

151

Lab 9

Copyright Oracle Corporation, 2007. All rights reserved.

152

Task Setting Up the Environment and Locating Utilities


1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the applmgr user. The applmgr user password is applmgr.
5. Navigate to the APPL_TOP directory (/appltop/apps/apps_st/appl).
6. Run the consolidated environment file for your E-Business Suite instance.
7. Verify that ORACLE_HOME is set to the 10.1.2 Oracle home, and that
TWO_TASK identifies the correct database.
8. Ensure that ORACLE_HOME/bin, FND_TOP/bin, and AD_TOP/bin are in your
PATH.
9. Go to the AD_TOP/bin directory.
10. Locate the AD utilities.

Copyright Oracle Corporation, 2007. All rights reserved.

153

Solution Setting Up the Environment and Locating Utilities


1. Start-up the NX Client, and connect to your server.
2. Login as nxuser1 with a password of oracle.
3. Open a terminal window.
4. Change (su) to the applmgr user. The applmgr user password is applmgr.
su - applmgr
5. Navigate to the APPL_TOP directory (/appltop/apps/apps_st/appl).
cd /appltop/apps/apps_st/appl
6. Run the consolidated environment file for your E-Business Suite instance.
. APPSVX0321_vx0321.env
Note: The above command will change based on the server and SID that you
have been assigned. The above command assumes that you have been
assigned the VX0321 SID on the vx0321 server.
7. Verify that ORACLE_HOME is set to the 10.1.2 Oracle home, and that
TWO_TASK identifies the correct database. Returned values will be similar to the
responses noted (in bold) after the commands.
echo $ORACLE_HOME
/appltop/apps/tech_st/10.1.2
echo $TWO_TASK
VX0321
8. Ensure that ORACLE_HOME/bin, FND_TOP/bin, and AD_TOP/bin are in your
PATH.
echo $ORACLE_HOME/bin
/appltop/apps/tech_st/10.1.2/bin
echo $FND_TOP/bin
/appltop/apps/apps_st/appl/fnd/12.0.0/bin

Copyright Oracle Corporation, 2007. All rights reserved.

154

echo $AD_TOP/bin
/appltop/apps/apps_st/appl/ad/12.0.0/bin
echo $PATH
/app/tech_st/10.1.3/perl/bin:/appltop/apps/tech_st/10.1.2/b
in:/appltop/apps/apps_st/appl/fnd/12.0.0/bin:/appltop/apps/
apps_st/appl/ad/12.0.0/bin:/appltop/apps/apps_st/comn/util/
jdk/jre/bin:/appltop/apps/apps_st/comn/util/unzip/unzip/unz
ip5.50::/appltop/apps/tech_st/10.1.2/bin:/usr/bin:/usr/ccs/bi
n:/usr/sbin:/app/tech_st/10.1.3/perl/bin:/appltop/apps/tech
_st/10.1.2/bin:/appltop/apps/apps_st/comn/util/jdk/jre/bin:
/appltop/apps/apps_st/comn/util/unzip/unzip/unzip5.50:/appltop/apps/tech_st/10.1.2/bin:/usr/bin:/usr/ccs/bin
:/usr/sbin:/zeus/perlbin:/perl/bin:/vmware/bin:/special/bin
:/home/ads/bin:/zeus/perlbin:/perl/bin:/vmware/bin:/special
/bin:/home/ads/bin:/home/ads/bin:/sbin:/zeus/perlbin:/perl/
bin:/vmware/bin:/special/bin:/home/ads/bin:/zeus/perlbin:/p
erl/bin:/vmware/bin:/special/bin:/home/ads/bin:/home/ads/bi
n:/sbin:/zeus/perlbin:/perl/bin:/vmware/bin:/special/bin:/h
ome/ads/bin:/usr/local/bin:/usr/bin:/usr/sbin:/usr/X11R6/bi
n:/bin:/usr/games:/opt/gnome/bin:/opt/kde3/bin:/usr/lib/mit
/bin:/usr/lib/mit/sbin:/usr/NX/bin:.:/usr/lib/qt3/bin:/apac
he/bin:/usr/lib/heartbeat:.:/apache/bin:/usr/lib/heartbeat:
.:/apache/bin:/usr/lib/heartbeat:.:/apache/bin:/usr/lib/hea
rtbeat:.:/apache/bin:/usr/lib/heartbeat:.:/appltop/apps/app
s_st/comn/util/jdk/bin:/appltop/apps/apps_st/comn/util/jdk/
bin
9. Go to the AD_TOP/bin directory.
cd $AD_TOP/bin

Copyright Oracle Corporation, 2007. All rights reserved.

155

10. Locate the AD utilities.


The AD utilities include the following: (this is not a complete list)
ls
adadmin

adaimgr

adcfginfo.sh

adchkcfg.sh

adchkdig

adchkutl.sh

adclone.sh

adconfig.sh

adctrl

adcvm.sh

addefgen

adrelink

adpatch

adsplice

adworker

Copyright Oracle Corporation, 2007. All rights reserved.

156

Lab 10

Copyright Oracle Corporation, 2007. All rights reserved.

157

Task 1: Allow Personalizations


1. Login to the E-Business Suite instance as SYSADMIN/SYSADMIN.
2. Select the Functional Administrator responsibility.
3. Navigate to the Core Services tab, and the Profiles subtab.
4. Set the Name field to Personalize%.
5. Click the Go button.
6. When the profile option, Personalize Self-Service Defn, is returned, click the
Update Value icon for that profile option.
7. Erase the value in the Site Value field.
8. Click the LOV icon.
9. In the LOV window that opens, click the Go button.
10. Click the Quick Select icon in Yes row of the table.
11. Confirm that the Site Value is now set to Yes.
12. Click the Update button.
13. Click the Home link on the header bar.
14. Click Logout on the header bar.

Copyright Oracle Corporation, 2007. All rights reserved.

158

Task 2: Personalize the Expenses Home Page


1. Login to the E-Business Suite instance as the OPERATIONS/WELCOME user.
2. Select the iExpenses responsibility.
3. Select the Personalize Page link.
Note: If you dont see this Personalize Page link on the header bar, you have not
done Task 1 correctly.

4. Select the Personalize icon on the Page Layout: Expenses Home item in the
Personalization Structure.

Copyright Oracle Corporation, 2007. All rights reserved.

159

5. Change the Title at the Site level from Inherit to Expenses Home (Personalized).
6. Select the Apply button.
7. Scroll to the bottom of the page.
8. Select the Return to Application link.

Copyright Oracle Corporation, 2007. All rights reserved.

160

9. Confirm that the Personalization has taken effect.

Copyright Oracle Corporation, 2007. All rights reserved.

161

Task 3: Create folders on the server


At customer site, personalizations are first done on a test instance, verified and then
deployed onto the production instance. For this demo, the test instance and the
production instance would be same the OU applications server
(vx0321.us.oracle.com). In this exercise, you want to extract personalization from MDS
repository and do some changes to the personalization document and import the
document back into the MDS repository.

1. Run Putty.

2. Set the Host Name as appropriate (for example, vx0321.us.oracle.com).


3. Select the Open button.

Copyright Oracle Corporation, 2007. All rights reserved.

162

4. Login as: applmgr


5. Password: applmgr
6. Enter pwd to verify the current directory. The current directory would be
/home/applmgr.
7. Create a folder as mkdir instructor.
8. Give full permission to the folder by entering chmod 777 instructor.
9. Create a second folder as mkdir instructor1.
10. Give full permission to the folder by entering chmod 777 instructor1.
11. You can exit the putty session.

Copyright Oracle Corporation, 2007. All rights reserved.

163

Task 4: Set the Personalization Document Root Path Profile


1. Login to the E-Business Suite instance as SYSADMIN/SYSADMIN
2. Select Functional Administrator responsibility.
3. Navigate to Core Services > Profiles.

4. Set the Code field to FND_PERZ_DOC_ROOT_PATH.


5. Select the Go button.
6. Update the profile and set the value to the instructor1 folder that you have
created on the server vx0321.us.oracle.com - /home/applmgr/instructor1.
7. Apply the changes and return to Home page.

Copyright Oracle Corporation, 2007. All rights reserved.

164

Task 5: Export the Personalizations to File System

1. Select the Personalization tab on the Functional Administrator page.


2. Select the Import/Export subtab.
3. Click the Focus icon beside the /oracle/apps/ap/oie path.

Copyright Oracle Corporation, 2007. All rights reserved.

165

4. Drill-down to the page that is being used for this demo. Choose
/oracle/apps/ap/oie/webui/customizations/site/0/HomePG.
5. Select the HomePG item in the structure.
6. Click Export to File System button to export the personalization document to the
file system. As the Personalization Document Root Path is set to
/home/nxuser1/instructor1 folder, the personalization document will be exported
to this folder.

Copyright Oracle Corporation, 2007. All rights reserved.

166

7. Click OK on the Export page.

Copyright Oracle Corporation, 2007. All rights reserved.

167

Task 6: Edit the Personalizations


1. Either restart Putty or switch back to the open session on the server
(vx0321.us.oracle.com).

Copyright Oracle Corporation, 2007. All rights reserved.

168

2. Type the following commands:


cp r instructor1/* instructor.
cd /home/user1/instructor/oracle/apps/ap/oie/webui/customizations/site/0

more HomePG.xml
3. Edit the personalization. Type the following commands:
vi HomePG.xml.
Use the arrow keys to move to the point in the
personalization file that reads (Personalized). Move the
cursor to be on the last parenthesis ). This should be line
4, column 71 of the file.
Press the i key.
Type <space>2. So, the file should read (Pesonalized 2).
Press the ESCape key.
Type :wq to exit vi and save your edits.
4. Confirm your edits. Type the command, more HomePG.xml.
5. You can exit the putty session.

Copyright Oracle Corporation, 2007. All rights reserved.

169

Task 7: Change the Personalization Document Root Path Profile


1. Navigate to Core Services > Profiles using the same Functional Administrator
responsibility.
2. Set the Code field to FND_PERZ_DOC_ROOT_PATH.
3. Select the Go button.
4. Update the profile and set the value to the instructor1 folder that you have
created on the server vx0321.us.oracle.com - /home/applmgr/instructor.
5. Apply the changes and return to Home page.

Copyright Oracle Corporation, 2007. All rights reserved.

170

Task 8: Import the Personalizations into the MDS repository


1. From the Functional Administrator responsibility, select the Personalization tab
and the Import/Export subtab.

2. Select Exported Personalizations from the side navigation menu.


3. Expand the Exported Personalizations and select
/oracle/apps/ap/oie/webui/customizations/site/0/HomePG.
4. Click on Import from File System button to import the updated personalization
document into the MDS repository.

Copyright Oracle Corporation, 2007. All rights reserved.

171

5. Click the OK button


6. Select the Home link at the top of the page.
7. Click the Logout link at the top of the page.
8. Login as OPERATIONS/WELCOME.
9. Select the iExpenses responsibility.

10. Confirm that the newly imported personalization is in place. Note: In order to see
the newly imported personalization, you may to clear the Global Cache which
you do from the Functional Administrator > Core Services > Caching Framework
> Global Configuration page.

Copyright Oracle Corporation, 2007. All rights reserved.

172

Lab 11

Copyright Oracle Corporation, 2007. All rights reserved.

173

Pre-requisites:
1. Login to the course server as SYSADMIN/SYSADMIN, use the System
Administrator responsibility, and add two responsibilities to the FWKTESTER
user.

OA Framework ToolBox Tutorial

OA Framework ToolBox Tutorial Labs

2. Move the QuerySolution.zip from your classroom PC to the server.


a. Start WinSCP.
b. Click the New button.
c. Set the Host name as appropriate (for example, vx0321.us.oracle.com).
d. Set the User name to nxuser1.
e. Set the Password to oracle.
f. Click the Login button.
Note: The QuerySolution.zip is stored on your classroom PC in the D:\Labs or
E:\Labs folder.
g. Change the left panel (Local Directory) to your D:\Labs or E:\Labs as
appropriate for your classroom PC.
h. Change the right panel (Server Directory) to
/home/nxuser1/jdevhome/jdev
i.

Drag-and-drop the QuerySolution.zip file from the left panel (Local) to the
right panel (Server) directory.

j.

Allow time for the upload to complete.

k. When file upload is complete, exit WinSCP.


3. Start the NX Client, and connect to your server.
4. Login as nxuser1 with a password of oracle.
5. Open a terminal window.

Copyright Oracle Corporation, 2007. All rights reserved.

174

6. Change to the $JDEV_USER_HOME directory.


cd $JDEV_USER_HOME
7. Unzip the QuerySolution.zip.
unzip QuerySolution.zip d $JDEV_USER_HOME
8. Start JDeveloper 10g with OA Extension.
JDev
9. Rebuild the ClassProject project.
10. Run the QueryPG to confirm your project is in place, and that it operates
properly.

The QuerySolution results in the following files:


1. ClassLabs.jws The workspace. This file is not needed for deployment.
2. ClassProject.jpr The project. This file is not needed for deployment.
3. ClassProject.jpx The BC4J Substitution file. This file is only needed when you
have extended BC4J objects in your code.
4. The QueryPG.xml and EmployeesLovRN.xml files for the UI elements.
5. The Java files in the JDEV_USER_HOME\myprojects\oracle path, and when
you have rebuilt your project the .class files in
JDEV_USER_HOME\myclasses\oracle path
Note: It is critical for the project to be rebuilt. For run-time usage of an OA
Framework page, you need the compiled Java object (.class) files not the source
(.java) files.

Copyright Oracle Corporation, 2007. All rights reserved.

175

Task 1: Copy all .class files to $JAVA_TOP


1. Zip the files in the JDEV_USER_HOME\myclasses\ directory into a file named,
deploydemo.zip.
zip r deploydemo.zip oracle*
2. Change the access privileges on deploydemo.zip.
chmod 777 deploydemo.zip
3. Change to the applmgr (E-Business Suite owner) user.
su - applmgr
Password: applmgr
4. Source the E-Business Suite instance environment variables.
.

/appltop/apps/apps_st/appl/APPSVX0321_vx0321.env

5. Copy the deploydemo.zip to $JAVA_TOP, and unzip it.


cp ./deploydemo.zip $JAVA_TOP
cd $JAVA_TOP
unzip deploydemo.zip d $JAVA_TOP
6. Bounce the E-Business Suite servers.
cd $INST_TOP/admin/scripts
.

./adstpall.sh apps/apps

<let the script run completely>


<It will shutdown all of the E-Business Suite>
<When completely down, type this command>
.

./adstrtal.sh apps/apps

Copyright Oracle Corporation, 2007. All rights reserved.

176

Task 2: Import the Page and Region into the MDS


1. Exit the applmgr user, and return to the nxuser1 user.
exit
2. Change to the directory where your UI files are located.
cd $JDEV_USER_HOME/myprojects
3. Import the QueryPG with the following command:
java oracle.jrad.tools.xml.importer.XMLImporter
./oracle/apps/ak/solution/employee/webui/QueryPG.xml
rootdir $JDEV_USER_HOME/myprojects
username apps password apps
dbconnection vx0321.us.oracle.com:1521:VX0321
4. Import the EmployeeLovRN with the following command:
java oracle.jrad.tools.xml.importer.XMLImporter
./oracle/apps/ak/solution/lov/webui/EmpNameLovRN.xml
rootdir $JDEV_USER_HOME/myprojects
username apps password apps
dbconnection vx0321.us.oracle.com:1521:VX0321

Copyright Oracle Corporation, 2007. All rights reserved.

177

Task 3: Register the Page within E-Business Suite


1. Login to the E-Business Suite instance as SYSADMIN/SYSADMIN.
2. Choose the Functional Administrator responsibility.
3. Select the Core Services tab.
4. Select the Functions subtab.
5. Click the Create Function button.
6. Set the Name to Student Deploy.
7. Set the Code to STUDENT_DEPLOY.
8. Set the Type to SSWA jsp function.
9. Click the Continue button.
10. Set the HTML Call to
OA.jsp?page=/oracle/apps/ak/instructor/employee/webui/QueryPG

11. Click the Submit button.


12. Return to the Home page.
13. Choose the Functional Administrator responsibility.
14. Select Core Services tab, and the Menus subtab.
15. Enter the Code as FWK_TBX_TUTORIAL_LABS_TOP.
16. Select the Go button.
17. Select the Update icon.
18. Select the Add Another Row button.
19. Set the Prompt to Query Page - Student.
20. Set the Function to Student Deploy.
21. Select the Apply button.
22. Close your browser session.

Copyright Oracle Corporation, 2007. All rights reserved.

178

Task 4: Bounce the E-Business Suite Instance


1. Return to the NX Client session.
2. Source the E-Business Suite instance environment variables.
.

/appltop/apps/apps_st/appl/APPSVX0321_vx0321.env

3. Bounce the E-Business Suite servers.


cd $INST_TOP/admin/scripts
.

./adstpall.sh apps/apps

<let the script run completely>


<It will shutdown all of the E-Business Suite>
<When completely down, type this command>
.

./adstrtal.sh apps/apps

Copyright Oracle Corporation, 2007. All rights reserved.

179

Task 5: Test Your New Page


1. Login to the E-Business Suite instance as FWKTESTER/FWKDEV.
2. Select the OA Framework ToolBox Tutorial Labs responsibility.
3. Select the Query Page Student link.
4. It should load/run the newly deployed page. Test to see that all is functional. For
example, put 1 in the Employee Number and then Go. Or put B% in the
Employee Name and then Go.

Copyright Oracle Corporation, 2007. All rights reserved.

180

Task 6: Remove Your Metadata


There are times when youve added metadata, a page, a personalization, or a BC4J
substitution, and it completely disrupts your server. The disruption can be so
complete that it makes it impossible to login to the E-Business Suite as that
particular user (or in worse-case scenarios, the whole E-Business Suite). You must
be able to undo the damage by cleaning up the MDS directly.
1. Start SQLDeveloper on your classroom PC. Since the metadata is in the
database, we can query it from any machine that has access to the database.
2. Connect to your database as apps/apps.
3. Open the Packages folder.
4. Scroll down to the JDR_UTILS package (or just start typing the name).
5. Right-click the JDR_UTILS package, and choose Run from the context menu.

Copyright Oracle Corporation, 2007. All rights reserved.

181

6. Select the LISTCONTENTS procedure from the Run PL/SQL window.

Copyright Oracle Corporation, 2007. All rights reserved.

182

7. Edit the P_PATH variable to /oracle/apps/ak/solution, and edit the


P_RECURSIVE variable to TRUE

8. Click the OK button.


9. In the Running Log window, your output will appear.

10. The LISTCONTENTS procedure takes two (2) parameters. Parameter 1,


P_PATH is the path to the package or document. In the example, you are looking
for all the documents and packages in the /oracle/apps/ak/solution hierarchy.
Parameter 2, P_RECURSIVE is TRUE when you want to recurse down the tree
looking for all the documents and packages in that hierarchy. The default is
FALSE. So, you want the parameter set to TRUE for the example.

Copyright Oracle Corporation, 2007. All rights reserved.

183

11. Currently, the only document in the MDS in the path of the
/oracle/apps/ak/solution path is QueryPG.
Note: For this example, there is only one (1) document. This is probably not the
case for an actual deployment. The LISTCONTENTS procedure will show
multiple documents, including PGs, RNs, personalizations, and BC4J
substitutions.
12. Right-click the JDR_UTILS package, and choose Run from the context menu.
13. Choose DELETEDOCUMENT from the Run PL/SQL window.
14. Edit the P_DOCUMENT variable to the complete path of the document you want
to delete from the MDS. For this example, that will be
/oracle/apps/ak/solution/employee/webui/QueryPG.

15. Click the OK button.

Copyright Oracle Corporation, 2007. All rights reserved.

184

16. You should see that your document was deleted successfully.
17. In addition to the QueryPG, there should also be an EmpNameLovRN in the
MDS. Delete that document using the same process.

Copyright Oracle Corporation, 2007. All rights reserved.

185

Lab 12

Copyright Oracle Corporation, 2007. All rights reserved.

186

Task 1: Design Your Menu


1. Login to your E-Business Suite instance as SYSADMIN/SYSADMIN.
Your objective is to create a menu specifically built towards OA Frameworkbased administration. Currently, the Functional Administrator responsibility has a
couple of areas of interest.
The Functional Administrator has the Personalization tab. On that tab, there are
two (2) subtabs, Application Catalog and Import/Export. On the Import/Export
page, there is a Sidebar Navigation that points to a Personalization Repository
(Import) page and a Exported Personalizations page.
Additionally, under the Functional Administrator responsibility, Core Services tab,
there is a Caching Framework subtab. There is a Sidebar Navigation on that
subtab, and one of the pages, Global Configuration, has interest to because you
use it to flush the global cache.
Finally, under the Core Services tab, we find ourselves occasionally using the
Messages, Profiles, Functions, and Menus subtabs to do Administration
functions.
2. You now have the basics to design a new menu, and a responsibility to go with
that menu. The details are as follows:
Responsibility

OA Framework Administrator

Menu
Personalizations (Tab 1)
Applications Catalog (Subtab 1)
Import Personalizations (Subtab 2)
Export Personalizations (Subtab 3)
Administration (Tab 2)
Profiles (Tab 1)
Messages (Tab 2)
Menus (Tab 3)
Functions (Tab 4)
Note: The Lab shows an example using existing OA Framework pages. The
process is no different for new OA Framework pages, except you would have to
Deploy the page (see the Lab Deploying Extensions for details).

Copyright Oracle Corporation, 2007. All rights reserved.

187

Task 2: Research Your Menu


1. Login to your E-Business Suite instance as SYSADMIN/SYSADMIN.
2. Choose the Functional Administrator responsibility.
3. Click the About this Page link. (Note: It doesnt matter which page in Functional
Administrator you choose to do this.)
4. Click the Page Context tab.
5. Look at the Menu section. The top-level menu for Functional Administrator is
FND_FUNC_ADMIN_ROOT.
6. Click the Return to Page link at the bottom of the page.
7. Click the Core Service tab.
8. Click the Menus subtab.
9. In the Code field, enter FND_FUNC_ADMIN_ROOT, and click the Go button.
10. Click on the Fnd Functional Administrator Root link in the results table. You
should see a page similar to the following:

11. Click the Hierarchy of Children tab on the Menus page.

Copyright Oracle Corporation, 2007. All rights reserved.

188

12. Click the Expand All link. You should see something similar to the following:

13. This is the structure of the Functional Administrator menu. The top-level of every
that will appear on the Personal Home Page is of the type, STANDARD. In this
case, it is the FND_FUNC_ADMIN_ROOT menu.
14. The next item is the type, HOMEPAGE. It is the menu that you actually see when
you see the entire menu. It is FND_FUNC_ADMIN_MENU.
15. A menu you might not have anticipated is the
ICX_STANDARD_GLOBAL_MENU, and it provides the standard buttons and
icons on every OA Framework page. You will need to add this to you menu.
16. From there, items are TABs, SUBTABs, SIDEBARs, or JSPs. JSPs are the
individual OA Framework pages.

Copyright Oracle Corporation, 2007. All rights reserved.

189

17. The individual pages (functions) you need to add to your menu are as follows:
Applications Catalog
Import Personalizations
Export Personalizations
Clear Global Cache
Profiles
Messages
Menus
Functions

Personalizations Search
Personalization Documents Import
Personalization Documents Delete and Export
Cache Component Global Configuration Page
Profile Administration
Maintain Messages
Menu Search
Menu Details
Function Search
Function Details

Note: Something that may be unexpected is the two (2) functions for menus and
functions. While you only have one (1) page directly on the menu, the other page
is accessible from the first. The way that E-Business Suite security functions is
that the page (function) must be on the menu in order for the user to access that
page. So, even though the page is not seen on the menu, it is included on the
menu for security purposes.
18. You now have enough information to implement your menu.

Copyright Oracle Corporation, 2007. All rights reserved.

190

Task 3: Implement Your Function


There is a unique function that tells your application which page to load first, and
what menu to use.
1. As SYSADMIN/SYSADMIN, navigate to the Functional Administrator
responsibility.
2. Choose the Core Services tab and the Functions subtab.
3. Click Create Function button.
4. Set the Name to Framework Administrator Home.
5. Set the Code to FWK_ADMIN_FUNC.
6. Set the Type to SSWA jsp function.
7. Click Continue button.
8. Set the HTML Call to OA.jsp?OAHP=FWK_ADMIN_HOME
&OAFunc=FND_PERSONALIZATIONS_SEARCH
9. Click Submit button.

Copyright Oracle Corporation, 2007. All rights reserved.

191

Task 4: Implement Your Menu


1. Login to your E-Business Suite instance as SYSADMIN/SYSADMIN.
2. Click the Core Service tab.
3. Click the Menus subtab.
Note: You create menus from the bottom to the top.
4. Click the Create Navigation Menu button.

5. Set the Name to OA Framework Administration Tab.


6. Set the Code to FWK_ADMIN_TAB.
7. Set the Description to OA Framework Administration Tab.
8. Set the Type to HTML Tab.
Note: You will now add the four (4) individual pages to this tab.
a. Click Add Another Row button.
b. Set the Prompt to Profiles.
c. Set the Function to Profile Administration.
Copyright Oracle Corporation, 2007. All rights reserved.

192

d. Click Add Another Row button.


e. Set the Prompt to Messages.
f. Set the Function to Maintain Messages.
g. Click Add Another Row button.
h. Set the Prompt to Menus.
i.

Set the Function to Menu Search.

j. Click Add Another Row button.


k. Leave the Prompt empty.
l.

Set the Function to Menu Details.

m. Click Add Another Row button.


n. Set the Prompt to Functions.
o. Set the Function to Function Search.
p. Click Add Another Row button.
q. Leave the Prompt empty.
r. Set the Function to Function Details.
s. Click the Apply button.
9. Click the Create Navigation Menu button.
10. Set the Name to OA Framework Personalization Tab.
11. Set the Code to FWK_PERZ_TAB.
12. Set the Description to OA Framework Personalization Tab.
13. Set the Type to HTML Tab.
Note: You will now add the four (4) individual pages to this tab.
a. Click Add Another Row button.
b. Set the Prompt to Personalization Catalog.
c. Set the Function to Profile Administration.

Copyright Oracle Corporation, 2007. All rights reserved.

193

d. Click Add Another Row button.


e. Set the Prompt to Import Personalizations.
f. Set the Function to Personalization Documents Import.
g. Click Add Another Row button.
h. Set the Prompt to Export Personalizations.
i.

Set the Function to Personalization Documents Delete and Export.

j. Click Add Another Row button.


k. Set the Prompt to Clear Global Cache.
l.

Set the Function to Cache Component Global Configuration Page.

m. Click the Apply button.


14. Click Create Navigation Menu button.
15. Set the Name to OA Framework Administrator Homepage.
16. Set the Code to FWK_ADMIN_HOME.
17. Set the Description to OA Framework Administrator Homepage.
18. Set the Type to Home Page.
Note: Add the two (2) tabs, Personalizations and Administration to the Home
page. Also, add the Global Menu.
a. Click Add Another Row button.
b. Leave the Prompt empty.
c. Set the Sub Menu to ICX_STANDARD_GLOBAL_MENU.
d. Click Add Another Row button.
e. Set the Prompt to Personalizations.
f. Set the Sub Menu to OA Framework Personalization Tab.
g. Click Add Another Row button.
h. Set the Prompt to Administration.
i.

Set the Sub Menu to OA Framework Administration Tab.


Copyright Oracle Corporation, 2007. All rights reserved.

194

j.

Click the Apply button.

19. Click Create Navigation Menu button.


20. Set the Name to OA Framework Administrator Top.
21. Set the Code to FWK_ADMIN_TOP.
22. Set the Description to OA Framework Administrator Top.
23. Set the Type to Standard.
Note: Add the Home Page to the Standard menu.
a. Click Add Another Row button.
b. Set the Prompt to Home
c. Set the Function to Framework Administrator Home Function.
d. Click Add Another Row button.
e. Leave the Prompt empty.
f. Set the Sub Menu to OA Framework Administrator Homepage.
g. Click the Apply button.
24. On the Navigation Menus page, enter FWK_ADMIN_TOP into the CODE field.
25. Click the Go button.
26. Click the OA Framework Administrator Top link.

Copyright Oracle Corporation, 2007. All rights reserved.

195

27. Click the Hierarchy of Children tab. Your page should look similar to the
following:

28. Click the Home link at the top of the page, and return to the Personal Home
Page.

Copyright Oracle Corporation, 2007. All rights reserved.

196

Task 5: Implement Your Responsibility


1. As SYSADMIN/SYSADMIN, navigate to the System Administrator responsibility,
and choose Security : Responsibility > Define.

2. Set the Responsibility Name to Framework Administrator.


3. Set the Application to Application Object Library.
4. Set the Responsibility Key to FWK_ADMIN.
5. Select the Available From: Oracle Self Service Web Applications.
6. Set the Data Group Name to Standard.
7. Set the Data Group Application to Application Object Library.
8. Set the Menu to OA Framework Administrator Top.
9. Save your work.
10. Stay in the Forms-based responsibility.

Copyright Oracle Corporation, 2007. All rights reserved.

197

Task 6: Modify Your User and Test


1. Navigate to Security : User > Define.
2. Query your <Your Name>_USER. (Note: To query, press F11 key, enter your
user name in the User Name field, and press the Ctrl+F11 key to execute the
query.)
3. Go to the Direct Responsibilities region, and insert a new row into the table. Click
the

icon to insert.

4. Add your Framework Administrator to the menu.


5. Save your work.
6. Exit the Forms-based responsibility, and return to the Personal Home Page.
7. Click the Logout link at the top of the page.
8. Login as your <Your Name>_USER E-Business Suite user.
9. Choose the Framework Administrator responsibility that is now on your menu.
Your menu/page structure should look similar to the following:

Copyright Oracle Corporation, 2007. All rights reserved.

198

Note: You may encounter a special quirk with the E-Business Suite, and you
should be aware of it and how to remedy it. When menus are created in the EBusiness Suite, a special Security Compilation process is started to compile the
menu into a useable object. Sometimes, when you create menus in Functional
Administrator (an OA Framework-based page), the compilation process doesnt
kick off immediately. This will become especially apparent when you make
multiple changes and save those changes to a menu. Depending upon the server
configuration, it can take up to an hour or more for compilation to succeed.
But, there is a work-around. Use the System Administrator responsibility, and
navigate to Application > Menu. Query your menu. Delete an item from the menu,
and save it. When you do, the compilation process will start immediately. Add the
item you just deleted back to the menu, and save again. Watch the concurrent
request until it is finished. Your menu should now be in good working order.

Copyright Oracle Corporation, 2007. All rights reserved.

199

Lab 13

Copyright Oracle Corporation, 2007. All rights reserved.

200

Task 1: Create a New Project


Step 1.1: Set-up the ExtendProject files
1. Move the ExtendStart.zip file from your classroom PC to the
$JDEV_USER_HOME directory on your server using WinSCP.
2. Start the NX Client, and login as nxuser1 with a password of oracle.
3. Change to the JDEV_USER_HOME directory.
cd $JDEV_USER_HOME
4. Unzip the ExtendStart.zip file.
unzip ExtendStart.zip d ./
5. Start JDeveloper 10g with OA Extension.
JDev

Step 1.2: Rebuild ClassProject Project


1. Select ClassProject in the Applications Navigator.
2. Right-click ClassProject, and choose Rebuild from the context menu.

Step 1.3: Create the new project


1. Right-click ClassLabs (Workspace), and choose New OA Project from the
context menu.
2. If the Welcome screen appears, click the Next button.
3. Set the Project Name to ExtendProject.
4. Set the Default Package to oracle.apps.ak.<your name>.
5. Click the Next button.
6. Click the Next button on Step 2 of 3: Database Connection page.
7. Set the DBC File Name (using the Browse button) to your
JDEV_USER_HOME/dbc_files/secure/<server>.dbc file, as appropriate.
8. Set the User Name to fwktester.
9. Set the Password to FWKDEV.
10. Set the Application Short Name to AK.
11. Set the Responsibility Key to FWK_TBX_TUTORIAL.
12. Click the Finish button.
13. Save your work.
14. Collapse (close) the ClassProject, if it is expanded (open).
15. Expand the ExtendProject, if it is collapsed.
Copyright Oracle Corporation, 2007. All rights reserved.

201

Step 1.4: Adjust the Project Properties


1. Double-click ExtendProject.
2. In the Project Content section, click the Add button.
3. Navigate down to oracle/apps/ak, and click the OK button. Then also add
oracle/apps/fnd. This will reduce the clutter in your project.
4. Expand the Oracle Applications section, and choose Run Options.
5. Move OADiagnostics from Available Options to Selected Options.
6. Click the OK button.
7. Save your work.

Step 1.5: Test Your Set-up


1. Expand the oracle.apps.fnd.framework.toolbox.tutorial.webui folder.
2. Run the PoSummaryCreatePG.
3. If the page runs, you have set-up everything correctly to this point in the lab. If
not, correct any errors, and re-run the page.

Copyright Oracle Corporation, 2007. All rights reserved.

202

Task 2: Add Attributes to an Existing BC4J Object


You will extend the Purchase Orders Summary page (PoSummaryCreatePG) to include
Supplier Site Name information in the table display. The following is the starting
condition of the page.

Step 2.1 Analyze What to Change


1. The XML file for the Purchase Orders summary page is:
oracle.apps.fnd.framework.toolbox.tutorial.webui.PoSummaryCreatePG.xml

Please note that the page full path, name and other OA References are available
directly from the About this page link on each page. The About this Page link
is displayed in diagnostics mode only.
In JDeveloper in ExtendProject.jpr, choose PoSummaryCreatePG.xml.
Examine its page structure and properties in the Property Inspector. An easy way
to analyze your page is to review the corresponding OA References window. To
show the OA References window for a page or a region, right-click the
PoSummaryCreatePG in the Structure pane and choose Show OA
References.
PoSummaryCreatePG contains an OrdersRN region under the PageLayoutRN
region. The OrdersRN region extends
/oracle/apps/fnd/framework/toolbox/tutorial/webui/PoSummaryRN as
indicated in the Extends property in the Property Inspector. The items under the
OrdersRN are grayed out because they inherit properties from the base region
that cannot be modified indirectly.
Choose PoSummaryRN.xml from the Navigator pane. The PoSummaryRN
region is a shared region that can be extended and reused by other pages and
Copyright Oracle Corporation, 2007. All rights reserved.

203

regions. PoSummaryRN contains an OrdersTable region. Note that all the items
under this region have the View Instance property set to PoSummaryVO1. Also
note that the Application Module Definition Name property is set only at the top
level (PoSummaryRN) to
oracle.apps.fnd.framework.toolbox.tutorial.server.PoSummaryAM.
Note again that you can analyze the PoSummaryRN through the OA
References window. To show the OA References window for a page or a region,
right-click the object in the Structure pane and choose Show OA References.
Please see Figures 8 and 9 for an example of the OA References and BC4J
Wizards screens.
Based on this analysis, we know that we need to extend the
oracle.apps.fnd.framework.toolbox.tutorial.server.PoSummaryVO to

add additional attributes.

Step 2.2 Create Your New View Object (VO)


1. Create a new VO.
2. Set the Package to oracle.apps.ak.<your name>.extend.server.
3. Set the Name to <Your Name>PoSummaryVO.
4. Set the Extends to
oracle.apps.fnd.framework.toolbox.tutorial.server.PoSummaryVO.

5. Click the Next button.


6. Move oracle.apps.fnd.framework.toolbox.schema.server.SupplierSiteEO entity
object from Available to Selected.
7. Select the Reference checkbox. You are going to use this entity object only for
read-only purposes.
8. Click the Next button.
9. Move the SupplierSiteId and SiteName attributes from the SupplierSiteEO
entity object Available to Selected panel.
10. Click the Next button on the Attributes page.
11. Click the Next button on the Attribute Settings page.

Copyright Oracle Corporation, 2007. All rights reserved.

204

12. Replace the Query Statement with the following:


SELECT PurchaseOrderHeaderEO.HEADER_ID,
PurchaseOrderHeaderEO.DESCRIPTION,
PurchaseOrderHeaderEO.STATUS_CODE,
PurchaseOrderHeaderEO.SUPPLIER_ID,
PurchaseOrderHeaderEO.CURRENCY_CODE,
PurchaseOrderHeaderEO.CREATION_DATE,
SupplierEO.NAME AS SUPPLIER_NAME,
SupplierEO.SUPPLIER_ID AS SUPPLIER_ID1,
EmployeeEO.FULL_NAME AS BUYER_NAME,
EmployeeEO.EMPLOYEE_ID,
PurchaseOrderHeaderEO.BUYER_ID,
EmployeeEO.EMAIL_ADDRESS AS BUYER_EMAIL,
(select sum(nvl(line.quantity, 0) * nvl(line.unit_price, 0))
from fwk_tbx_po_lines line
where line.header_id = PurchaseOrderHeaderEO.HEADER_ID)
AS ORDER_TOTAL,
decode(PurchaseOrderHeaderEO.STATUS_CODE,
'APPROVED', 'okind_status.gif',
'COMPLETE', 'completeind_status.gif',
'REJECTED', 'criticalind_status.gif', 'inprogressind_status.gif')
AS STATUS_IMAGE,
LookupCodeEO.MEANING AS STATUS_DISPLAY,
decode(PurchaseOrderHeaderEO.STATUS_CODE,
'COMPLETE', 'DeleteDisabled',
'APPROVED', 'DeleteDisabled', 'DeleteEnabled') AS DELETE_IMAGE,
decode(PurchaseOrderHeaderEO.STATUS_CODE,
'COMPLETE', 'UpdateDisabled',
'APPROVED', 'UpdateDisabled', 'UpdateEnabled') AS UPDATE_IMAGE,
decode(PurchaseOrderHeaderEO.STATUS_CODE,
'COMPLETE', 'Y',
'APPROVED', 'Y', 'N') AS APPROVE_DISABLED,
SupplierSiteEO.SUPPLIER_SITE_ID,
SupplierSiteEO.SITE_NAME
FROM FWK_TBX_PO_HEADERS PurchaseOrderHeaderEO,
FWK_TBX_SUPPLIERS SupplierEO,
FWK_TBX_EMPLOYEES EmployeeEO,
FWK_TBX_LOOKUP_CODES_VL LookupCodeEO,
FWK_TBX_SUPPLIER_SITES SupplierSiteEO
WHERE
PurchaseOrderHeaderEO.SUPPLIER_ID = SupplierEO.SUPPLIER_ID
AND PurchaseOrderHeaderEO.STATUS_CODE = LookupCodeEO.LOOKUP_CODE
AND LookupCodeEO.LOOKUP_TYPE = 'FWK_TBX_ORDER_STATUS'
AND PurchaseOrderHeaderEO.BUYER_ID = EmployeeEO.EMPLOYEE_ID
AND SupplierEO.SUPPLIER_ID = SupplierSiteEO.SUPPLIER_ID
AND PurchaseOrderHeaderEO.SUPPLIER_SITE_ID =
SupplierSiteEO.SUPPLIER_SITE_ID
ORDER BY PurchaseOrderHeaderEO.HEADER_ID

13. Click the Test button, and successfully test your SQL statement.
14. Click the Next button.
15. Click the Next button on the Bind Variables page.
Copyright Oracle Corporation, 2007. All rights reserved.

205

16. On the Java section, uncheck the View Object Class - Generate Java File
checkbox.
17. Check the View Row Class - Generate Java File and Generate Accessors
checkboxes.
18. Click the Finish button.

Step 2.3: Correcting the XML


There is a known error with extended VOs. This error has been corrected in JDeveloper
11g. Unfortunately, OA Framework is based on JDeveloper 10g. You need to correct
the generated XML for the VO.
What is wrong? Double-click <Your Name>PoSummaryVO. Choose Attribute Mappings,
and scroll to the bottom of the list. You will note that SupplierSiteId and SiteName in the
query column are designated as (Transient). This designation means they are not part
of the query. This is wrong. They are part of the query. You just added them.
While this may seem a bit extreme, it is a useful learning opportunity. No tool is 100%
perfect. You should be able to look at the generated files, and fix errors if needed. To
correct this error, perform the following steps.
1. Exit JDeveloper 10g with OA Extension, and return to your shell.
2. On the Linux desktop, click the My Computer icon.
3. Choose the My Home Folder link, under Common Folders.
4. Click the following folders to navigate to the proper subdirectory
jdevhome > jdev > myprojects > oracle > apps > ak > <your name> >
extend > server
5. Right-click the <Your Name>PoSummaryVO.xml file, and choose Open With >
Other from the context menu.
6. In the Open With windows, expand the Tools > Editor folder, and select KWrite.
7. Select the Remember application association for this type of file checkbox, and
click the OK button.
8. The XML file will open in KWrite.
9. Scroll to the bottom of the file. The generated XML is wrong. Replace the XML
that reads:

Copyright Oracle Corporation, 2007. All rights reserved.

206

<ViewAttribute
Name="SupplierSiteId"
IsUpdateable="false"
IsPersistent="false"
Type="oracle.jbo.domain.Number"
ColumnType="NUMBER"
AliasName="SUPPLIER_SITE_ID"
SQLType="NUMERIC" >
</ViewAttribute>
<ViewAttribute
Name="SiteName"
IsSelected="false"
IsPersistent="false"
Precision="255"
Type="java.lang.String"
ColumnType="VARCHAR2"
AliasName="SITENAME"
SQLType="VARCHAR" >
</ViewAttribute>
Replace it with the following correct XML.
<ViewAttribute
Name="SupplierSiteId"
IsUpdateable="false"
EntityAttrName="SupplierSiteId"
EntityUsage="SupplierSiteEO"
AliasName="SUPPLIER_SITE_ID" >
</ViewAttribute>
<ViewAttribute
Name="SiteName"
IsUpdateable="false"
EntityAttrName="SiteName"
EntityUsage="SupplierSiteEO"
AliasName="SITE_NAME" >
</ViewAttribute>
10. Choose (Menu) File > Save, or press Ctrl+S.
11. Choose (Menu) File > Quit, or press Ctrl+Q.
12. Restart JDeveloper 10g with OA Extension.
13. Double-click <Your Name>PoSummaryVO.
14. Choose Attribute Mappings, and scroll to the bottom of the list.

Copyright Oracle Corporation, 2007. All rights reserved.

207

15. You will note that SupplierSiteId and SiteName in the query column are not
designated as (Transient). If they are, you did not edit the proper file, or save
your changes.

Step 2.4: Substitute Your New VO for the Parent VO


1. Double-click ExtendProject in the Applications Navigator pane to open the
Project Properties page.
2. Expand the Business Component category, and select Substitutions.
3. From the Available list, select the base object
oracle.apps.fnd.framework.toolbox.tutorial.server.PoSummaryVO that you want to

replace.
4. From the Substitute list, select the extended object oracle.apps.ak.<your
name>.extend.server.<YourName>PoSummaryVO) that you want as the
substitute.
5. Click the Add button. A new substitution rule will be added in the Substitutions list
box.
6. Click the Run/Debug category in the Project Properties.
7. Click the Edit button.
8. Add the following to the java Options field:
-Djbo.project=ExtendProject
Be sure to put a space before any existing options and adding this option.
Note: If you forget to add this jbo.project Java option, you will get exceptions like
"oracle.apps.fnd.framework.OAException: oracle.jbo.NoDefException: JBO25002: Definition SiteName of type Attribute not found". The reason is that the
runtime environment does not pick up substitution rules, and hence BC4J tries to
find the new attribute from the base object and not the extended object.
9. Click the OK button.
10. Click the OK button.
11. Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

208

Step 2.5: Make a Copy of the Target Page


1. At the operating system shell, make a copy of the file
<JDEV_USER_HOME>/myprojects/oracle/apps/fnd/framework/toolbox/
tutorial/webui/PoSummaryCreatePG.xml as
<JDEV_USER_HOME>/myprojects/oracle/apps/ak/<your name>/extend/
webui/<Your Name>PoSummaryCreatePG.xml
2. Refresh the files in ExtendProject (Menu > View > Refresh).
Note: When you refresh, you should see your oracle.apps.ak.<your name>.
extend.webui folder added to your project.

Step 2.6: Modify Your Copy of the Target Page


1. Modify the Window Title and the Title properties of the <Your
Name>PoSummaryCreatePG page (in the PageLayoutRN) to include your own
name so you can verify later that your personalizations affect the correct page.
2. Save your work.

Step 2.7: Personalize the UI to Display the New Attribute


1. Rebuild ExtendProject, and make sure you have no errors.
2. Run the <Your Name>PoSummaryCreatePG.xml page.
3. Select the Personalize Page global link.

4. In the Personalize Page page, check the Complete View radio button for the
Personalization Structure. Expand the Stack Layout: Purchase Order Summary
Region node, locate the Table: Purchase Orders Table entry in the page
hierarchy and select the Create Item icon.
5. In the Create Item page:
a. Set the Item Style to Message Styled Text.
b. Set the ID to SiteName.
c. Set the Prompt to Supplier Site
d. Set the View Attribute to SiteName
e. Set the View Instance to PoSummaryVO1
f. Select the Apply button

Copyright Oracle Corporation, 2007. All rights reserved.

209

6. Locate the Table: Purchase Orders Table entry again and select the Reorder
icon.
7. In the Reorder Contents of Table page's Site list, move the Supplier Site item to
be sequenced immediately after the Supplier item.
8. Select the Apply button.
9. Select the Return to Application link. Now you should see the Supplier Site
column added to the Orders Table.
Note: We set the View Instance to PoSummaryVO1 and not
<Your Name>PoSummaryVO1. The BC4J substitution will take care of properly
creating an instance of <Your Name>PoSummaryVO1 at runtime in place of the
PoSummaryVO1.

Step 2.8: Verify Personalization Changes


Run the original PoSummaryCreatePG.xml file from JDeveloper and verify that your
personalization and extension changes have been applied.

Copyright Oracle Corporation, 2007. All rights reserved.

210

Lab 14

Copyright Oracle Corporation, 2007. All rights reserved.

211

Task 1: Defaulting Attributes


Note: You can default simple values using personalizations without adding or modifying
code. If you need conditional defaulting, this lab shows you the appropriate method.
You will extend the Purchase Orders Create page to default the Payment Terms field
to Net 60.

Step 1.1: Analyze What to Change


1. Run the <Your Name>PoSummaryCreatePG from the Adding Attributes lab.
2. Click the Create Purchase Order (Basic Train) button. The Create Purchase
Order: Description page will appear.

3. Click the About this Page link, and analyze the page.
4. The XML file for the Purchase Orders create page - step 1 is
/oracle/apps/fnd/framework/toolbox/tutorial/webui/PoDescPG.xml.

5. In your ExtendProject, select PoDescPG.xml and examine its page structure and
properties in the Property Inspector. An easy way to analyze your page is to
review the corresponding OA References window. To show the OA References
window for a page or a region, right-click the object in the Structure pane and
choose Show OA References.
PoDescPG contains a MainRN region under the PageLayoutRN region. Note
that all the items under this region have the View Instance property set to
PoDetailsFullVO1. That is also obvious from the OA References window.

Copyright Oracle Corporation, 2007. All rights reserved.

212

If you open PoDetailsFullVO, it contains PurchaseOrderHeaderEO (in


oracle.apps.fnd.framework.toolbox.schema.server package), which
includes the attribute PaymentTermsCode. Defaulting or validation logic goes
into the Entity Object Java class instead of into the View Object Java class.
Centralizing the defaulting/validation logic in the Entity Object layer promotes
reuse and sharing of the business logic. Based on the analysis, you need to
extend the PurchaseOrderHeaderEO to change the default value for the
PaymentTermsCode.
Note: You will extend the XML and the Java classes to make use of the BC4J
substitution instead of just extending the Java classes. BC4J substitution works
on the XML.

Step 1.2: Create Your New Entity Object (EO)


1. Create a new Entity Object.
a. Set the Name to <Your Name>PurchaseOrderHeaderEO.
b. Set the Package to
oracle.apps.ak.<your name>.extend.schema.server.

c. Set the Extends Entity field to


oracle.apps.fnd.framework.toolbox.schema.server.PurchaseOrderHeaderEO.

d. Click the Next button.


e. On the Attributes page, click the New from Table button.
f. Move all the attributes from available to selected, and click the OK button.
g. Click the Next button until you get to the Java page.
h. Generate the create method.
i.

Do not generate accessors.

j. Click the Next button.


k. Do not generate the default view object.
l. Click the Finish button.

Step 1.3: Add the Defaulting Logic


1. Edit <Your Name>PurchaseOrderHeaderEOImpl Java class.
2. Edit the create() method as follows:

Copyright Oracle Corporation, 2007. All rights reserved.

213

/**
* Initializes a new purchase order header.
*/
public void create(AttributeList attributeList)
{
super.create(attributeList);
// Add or change the default values here.
setPaymentTermsCode("NET_60");
}
Note: The create method is invoked when the Entity Object is created. You set
default values in this method. Also note that you should call the
super.create(attributeList) method before adding your custom defaulting logic.

Step 1.4: Delete Invalid Code


Because you are using older OA Framework objects (a common occurrence when
extending objects), there is code in those older objects that no longer works. It will
generate error messages as follows:

Copyright Oracle Corporation, 2007. All rights reserved.

214

You must edit the PurchaseOrderHeaderEOImpl.java file, and remove the offending
code from the following methods:
setStatusCode
setHeaderId
setBuyerId
setPaymentTermsCode
setCarrierCode
setCurrencyCode
1. Edit each method, and remove all the code from the method, except for one (1)
line. Your method code should look similar to the following:
{
setAttributeInternal(STATUSCODE, value);
} // end setStatusCode()
2. Each method will vary slightly. But, you will see the setAttributeInternal method
call in each of the methods.
3. Save your work.
4. Rebuild ExtendProject, and resolve any errors.

Step 1.5: Set Profile Option


When you set default values, either through personalizations or extensions, there is a
Profile Option, FND:OA:Enable Defaults that must be set in order to see your default
values.
1. Login to the E-Business Suite as SYSADMIN.
2. Choose the Functional Administrator responsibility.
3. Navigate to Core Services > Profiles.
4. Query the FND:OA:Enable Defaults profile option at the Site level.
5. Change the profile to a value of Yes.
6. Save your change to the profile option.
7. Flush the Global Cache.

Copyright Oracle Corporation, 2007. All rights reserved.

215

Step 1.6: Substitute Your New EO for the Parent EO


1. Double-click ExtendProject in the Applications Navigator pane to open the
Project Properties page.
2. Expand the Business Component category, and select Substitutions.
3. From the Available list, select the base object
oracle.apps.fnd.framework.toolbox.schema.server.PurchaseOrderHeaderEO

that you want to replace.


4. From the Substitute list, select the extended object oracle.apps.ak.<your
name>.extend.schema.server.<Your Name>PurchaseOrderHeaderEO
that you want as the substitute.
5. Click the Add button. A new substitution rule will be added in the Substitutions list
box.
6. Click the OK button.

Step 1.7: Run the Page


1. Rebuild ExtendProject, and resolve any errors.
2. Run the <Your Name>PoSummaryCreatePG page. Once the page is rendered,
click the Create Purchase Order (Basic Train) button.
3. The extended page should render with the Payment Terms field correctly
defaulted to Net 60.

Copyright Oracle Corporation, 2007. All rights reserved.

216

Note: There is an unusual error that occurs on this page that bears some
discussion. In the standards for OA Framework BC4J items, the items are limited to
30 characters. If you put in the longer name and run the page, the Payment Terms
item will not default. But, no error message will be generated. It is ONLY when you
run the page in the Debugger that you will see and generate an error message. The
error message will tell you that the identifier is too long. In other words, you have
exceeded the 30-character limit.

Copyright Oracle Corporation, 2007. All rights reserved.

217

Lab 15

Copyright Oracle Corporation, 2007. All rights reserved.

218

Task 1: Extend the BC4J Validation Logic


While the minimum wage varies, the company has a corporate-standard minimum wage
of $10.00 per hour. Since all employees of the company are full-time employees, this
works out to an annual minimum salary of $20,800. You will extend the CreatePG to
throw a validation error when a salary below $20,800 is entered. Since this validation
error doesnt exist in the message dictionary, you will also need to create the
appropriate error message in the message dictionary.

Step 1.1: Analyze What to Change


1. Run the oracle.apps.ak.solution.employee.webui.QueryPG page.
2. Click the Create Employee button.
3. Click the About this Page link.
4. The XML file for the Solution Create page is
/oracle/apps/ak/solution/employee/webui/CreatePG.xml.
Please note that the page full path, name and other OA References are available
directly from the About this Page link on each page.
Examine the page structure and properties in the OA References window or the
Property Inspector.
5. CreatePG contains a MainRN region under the PageLayoutRN region hierarchy.
Note that all the items under this region have the View Instance property set to
DetailsVO1.

Copyright Oracle Corporation, 2007. All rights reserved.

219

6. If you expand the Business Component References Details section, you will note
the DetailsVO uses FwkTbxEmployeesEO (in
oracle.apps.ak.solution.schema.server package), which includes the
attribute Salary. Defaulting or validation logic goes into the Entity Object Java
class instead of into the View Object Java class. Centralizing the
defaulting/validation logic in the Entity Object layer promotes reuse and sharing
of the business logic.
Based on this analysis, we know that we need to extend the
oracle.apps.ak.solution.schema.server.FwkTbxEmployeesEO to add the

validation logic for Salary.

Step 1.2: Create Your New EO


1. Select the oracle.apps.ak.<your name>.extend.schema.server BC4J
package in the Navigator and choose New Entity Object... from the context
menu to create a new Entity Object called
<Your Name>FwkTbxEmployeesEO.
2. Set the Extends Entity text input field to FwkTbxEmployeesEO under
oracle.apps.ak.solution.schema.server.
3. Click the Next button.
4. On the Attributes page, click the New From Table button. Move all the
attributes from Available to Selected, and click the OK button.
5. Skip to the Java page, and deselect Generate Accessors.
6. Skip to last step of the Entity Object wizard and make sure that Generate Default
View Object is unchecked.
7. Click the Finish button.
8. Save your work.

Step 1.3: Add Your Validation Logic


Note: You can add simple validation logic using the JDeveloper BC4J Wizards. For
complex scenarios you can add the code directly as in the following example.
1. Edit <Your Name>FwkTbxEmployeesEOImpl.java class. Confirm it extends
FwkTbxEmployeesEOImpl.java class and add the following imports:
import oracle.jbo.domain.Number;
import oracle.apps.fnd.framework.OAAttrValException;
import oracle.apps.fnd.framework.OAException;

Copyright Oracle Corporation, 2007. All rights reserved.

220

2. Add the following code within the public class, and rebuild the project.
public void setSalary(Number value)
{
if (value != null)
{
// Verify value is >= 20800.
if (value.compareTo(20800) < 0)
{
throw new OAAttrValException(OAException.TYP_ENTITY_OBJECT,
getEntityDef().getFullName(),
// EO name
getPrimaryKey(),
// EO PK
"Salary",
// Attribute Name
value,
// Attribute value
"AK",
// Message prod short name
"FWK_CORP_MINIMUM_SALARY"); // Message name
}
}
super.setUnitPrice(value);
}

3. Attribute Level Validation: The attribute setter methods (setSalary) are invoked
when the user-entered values are set in the Entity Object. Note that you want to
execute your custom validation before calling super.setSalary(value) since the
super's method actually sets the new value on the entity object, and you don't
want to do this if the value is invalid.
4. Entity Level Validation: For a single attribute validation, you can override the
attribute setter method as illustrated. If you want to perform cross-attribute
validation, then you need to override the validateEntity() method. For an example,
see the validateEntity() method.
5. Attribute Level Exception vs. Entity Level Exception: For attribute level
exceptions, use OAAttrValException as illustrated. For entity level exceptions,
use OARowValException. For an example of an OARowValException, see the
remove() method.

Step 1.4: Substitute Your New EO for the Parent EO


1. Double-click ExtendProject in the Applications Navigator pane to open the
Project Properties page.
2. Expand the Business Component category, and select Substitutions.
3. From the Available list, select the base object
oracle.apps.ak.solution.schema.server.FwkTbxEmployeesEO that
you want to replace.
4. From the Substitute list, select the extended object oracle.apps.ak.<your
name>.extend.schema.server.<Your Name>FwkTbxEmployeesEO that
you want as the substitute.
Copyright Oracle Corporation, 2007. All rights reserved.

221

5. Click the Add button. A new substitution rule will be added in the Substitutions list
box.
6. Click the OK button.

Step 1.5: Create the Message in the Message Dictionary


Currently, the message, FWK_CORP_MINIMUM_SALARY does not exist in the
message dictionary. If you tried to test your page, it would not run if the message was
generated. You need to create this message in the message dictionary.
1. Login to your E-Business Suite instance as SYSADMIN/SYSADMIN.
2. Choose the Functional Administrator responsibility.
3. Choose the Core Services tab, and choose the Messages subtab.
4. Click the Create Message button.
5. Set the Code to FWK_CORP_MINIMUM_SALARY.
6. Set the Description to Customizing Adding Validation Lab.
7. Set the Application Name to Common Modules-AK.
8. Set the Language to American English.
9. Set the Text to The corporate standard minimum wage is $10/hour or
$20,800/annual salary.oracle

Step 1.6: Run the Page


1. Rebuild ExtendProject, and resolve any errors.
2. Run the QueryPG page. Once the page is rendered, select the "Create
Employee" button.
3. Enter a Number of your choice over 10000, and it must be unique. If you have
used this number on previous tests, you can not reuse it.
4. Enter a First Name of your choice.
5. Enter a Last Name of your choice.
6. Set the Position to President.
7. Set the Salary, which defaults to 68320, to 12000.
8. Set the Hire Date to the current date. Use the Calendar quick select if you like.
Copyright Oracle Corporation, 2007. All rights reserved.

222

9. Click the Apply button.


10. Note the exception message that appears.

Copyright Oracle Corporation, 2007. All rights reserved.

223

Lab 16

Copyright Oracle Corporation, 2007. All rights reserved.

224

Quick Guide:
The following is a Quick Guide to the steps needed to assemble the components for an OA
Framework page.

1. Analyze the page using the About this Page link. Identify all of the following
components:
a. Complete path to PG
b. Complete path to all basic AMs/VOs
c. Complete path to all EOs
d. Applications username, password, and responsibility key
e. Any Controllers on the page
2. Zip the appropriate .class and .xml files (BC4J objects and COs).
3. Download the .zip to the development environment
4. Go to the Development environment
5. Unzip Tutorial.zip into your designated JDEV_USER_HOME as a starting point
6. Unzip the downloaded .zip file with the .class and .xml files to your
JDEV_USER_HOME/myclasses directory
7. export (xmlexporter) the PG into your JDEV_USER_HOME/myprojects directory
8. Launch JDeveloper
9. Create a new OA Workspace and OA Project
a. Add OADiagnostics to the Runtime settings
b. Point your project to the DBC file for your test instance
c. If necessary, download the DBC file from your test instance
$FND_TOP/secure directory
d. Set your project to use the username, password, and responsibility key
identified for the page
10. Add the EOs server.xml to the project, and the AMs/VOs server.xml to the
project. If either of these doesnt exist, log a SR with Oracle Support requesting
this file from Development. You can add the individual components manually, but
it is more time-consuming.
11. Add the COs to the project.
12. Add the PG to the project.
13. Test run the PG, and revise your project until the PG no longer produces errors.

Copyright Oracle Corporation, 2007. All rights reserved.

225

Task 1: Analyze the Page


In this task, you are going to do a detailed analysis of the page to understand what
components you will need in order to extend these pages.

Step 1.1: Begin the Analysis


1. Rebuild ExtendProject.
2. Run the oracle.apps.ak.solution.employee.webui.QueryPG.
3. Click the About this Page link.
You need to collect the following information for any page you analyze.
(Note: All names MUST BE complete paths)

Page Name
Any Controllers (COs) associated with the page
Pages Application Module (AM)
Pages View Objects (VOs)
Pages Entity Object (EOs) (if any)

Copyright Oracle Corporation, 2007. All rights reserved.

226

Collect the following for your QueryPG:


Page Name:

___________________________________________________

Controller:

___________________________________________________

AM:

___________________________________________________

VOs:

___________________________________________________
___________________________________________________
___________________________________________________

EOs:

___________________________________________________

(See next page for answers.)

Copyright Oracle Corporation, 2007. All rights reserved.

227

Page Name:

/oracle/apps/ak/solution/employee/webui/QueryPG

Controller:

ResultsCO

AM:

oracle.apps.ak.solution.employee.server.QueryAM

VO:

oracle.apps.ak.solution.employee.server.QueryVO
oracle.apps.ak.region.server.AkAmParameterRegistryVO
oracle.apps.fnd.framework.server.OADynamicPoplistVO

EO:

oracle.apps.ak.<Your Name>.extend.schema.server.
<Your Name>FwkTbxEmployeesEO

How do you discover the information about the AMs, Controllers, VOs, and EOs? You
have 2 options.
1. Click the Hide/Show icon labeled Business Component References Details, and
you will see the page change to look similar to the following.

Copyright Oracle Corporation, 2007. All rights reserved.

228

2. Click the Printable Page button at the top of the About page, and collect all the
expandable information in 1 step. That information looks similar to the following:

When you have collected the information, click the Return to Page: Employees: Solution
link at the bottom of the About page.

Copyright Oracle Corporation, 2007. All rights reserved.

229

Task 2: Assemble the Page Components


Note: The assumption is that all the component pieces are obtained from the server.
The chapters in the course covering Deployment cover the details of obtaining those
pieces. For sake of simplicity and ease of implementation, you will copy those pieces
from your own file system. However, the locations where those files are stored on the
Development machine are consistent with standards.
Step 2.1: Change Your JDEV_USER_HOME Variable
Normally, you would not do this. But, you are simulating getting files from the server. To
do this, you need to point your JDEV_USER_HOME to another directory.
1. In the terminal window input the following commands:
cd $HOME
mkdir jdevhome2
cd jdevhome2
mkdir jdev
unzip /JDev/jdevbin/Tutorial.zip
2. Continuing in the same terminal window, input the following command:
export JDEV_USER_HOME=/home/nxuser1/jdevhome2/jdev
Step 2.2: Move the DBC file and Other Set-up Tasks
1. In the terminal window, input the following commands:
cd $JDEV_USER_HOME
rm r myprojects
cd dbc_files/secure
cp /home/nxuser1/jdevhome/jdev/dbc_files/secure/<Your>.dbc ./

cd ../..
mkdir myprojects
mkdir myclasses

Copyright Oracle Corporation, 2007. All rights reserved.

230

2. Beneath both the myprojects and myclasses directories, create the following
structure.
myprojects/myclasses
- oracle
- apps
- ak
- solution
- employee
- server
- webui
- schema
- server
mkdir p myprojects/oracle/apps/ak/solution/employee/server
mkdir p myprojects/oracle/apps/ak/solution/employee/webui
mkdir p myprojects/oracle/apps/ak/solution/schema/server
mkdir p myclasses/oracle/apps/ak/solution/employee/server
mkdir p myclasses/oracle/apps/ak/solution/employee/webui
mkdir p myclasses/oracle/apps/ak/solution/schema/server
Step 2.3: Move the MDS Related Components
In Framework pages and applications, there are three (3) kinds of components stored in
the MDS.
1. Pages
2. Personalizations
3. BC4J Substitutions
Assume you have used the export command to download the page from the MDS.
Assume that it is in the file system of your server. You now need to move the file from
the server (which is going to be your old JDEV_USER_HOME directory) to your
Development machine (which is your new JDEV_USER_HOME directory).
cp <from> <to>
From: /home/nxuser1/jdevhome/jdev/myprojects/oracle/apps/ak/
solution/employee/webui/QueryPG.xml
To: /home/nxuser1/jdevhome2/jdev/myprojects/oracle/apps/ak/
solution/employee/webui/QueryPG.xml
Copyright Oracle Corporation, 2007. All rights reserved.

231

Step 2.4: Move the BC4J and Controller Components


In Framework pages, there are several BC4J components. Each of those components
can have multiple files. Those files are as follows:
Application Module (AM):
View Objects (VO):
Entity Objects (EO):
Controllers (CO):

<name>AM.xml
<name>AMImpl.class
<name>VO.xml
<name>VORowImpl.class
<name>VOImpl.class (dependent file)
---see note below--<name>CO.class

About EOs and related objects: In the About this Page info, only directly related EOs
(i.e., those EOs directly associated with VOs) will be shown in the diagnostic summary.
However, there can be numerous other files at the EO-layer of Framework that need to
be present in order for the page to run. These include files like the following:

Associate Objects (AO)


Validation Application Modules (VAM)
Validation View Objects (VVO)
Entity Experts (EntityExpert.class)

When you are downloading files from the server, it is best to grab everything related to
the EO. You might grab some unneeded files, but it will save you time and frustration in
the long run.
By naming standards, EO-layer objects are kept in the ./schema/server path. So,
in our example, we would want to move ALL the objects as follows:
From: /home/nxuser1/jdevhome/jdev/myclasses/oracle/apps/ak/
solution/schema/server/
To:
/home/nxuser1/jdevhome2/jdev/myclasses/oracle/apps/ak/
solution/schema/server/
1. Copy the Controller files:
From:

/home/nxuser1/jdevhome/jdev/myclasses/oracle/
apps/ak/solution/employee/webui/ResultsCO.class

To:

/home/nxuser1/jdevhome2/jdev/myclasses/oracle/
apps/ak/solution/employee/webui/ResultsCO.class

Copyright Oracle Corporation, 2007. All rights reserved.

232

2. Copy the AM files:


From:

/home/nxuser1/jdevhome/jdev/myclasses/oracle/
apps/ak/solution/employee/server/QueryAM*.*

To:

/home/nxuser1/jdevhome2/jdev/myclasses/oracle/
apps/ak/solution/employee/server/

3. Copy the VO files:


From:

/home/nxuser1/jdevhome/jdev/myclasses/oracle/
apps/ak/solution/employee/server/QueryVO*.*

To:

/home/nxuser1/jdevhome2/jdev/myclasses/oracle/
apps/ak/solution/employee/server/

4. Copy the EO-layer files:


From:

/home/nxuser1/jdevhome/jdev/myclasses/oracle/
apps/ak/solution/schema/server/*.*

To:

/home/nxuser1/jdevhome2/jdev/myclasses/oracle/
apps/ak/solution/schema/server/*.*

Note: When you copy all the EO-layer files, you will also copy over some
configuration files used by JDeveloper. These files would not be stored on the
actual server, and are therefore unnecessary. Delete them if you like to ensure
that they are not needed. JDeveloper will recreate these files if they are not
present.
Step 2.5: Start JDeveloper and Test
1. Start JDeveloper.
2. Create a new OA Workspace. Give it the File Name, AssemblySpace.
3. Create a new OA Project. Give it the Project Name, AssemblyLab. The default
package should be oracle.apps.ak.solution.
4. Make certain to use the proper DBC file associated with your server.
5. Set the password for FWKTESTER to FWKDEV (or your setting).
6. Finish creating the workspace and project.
7. Your View-layer object (QueryPG) will automatically be added to the project.
8. Run QueryPG to test.
9. You will get an error message. You will also get some compilation warnings.

Copyright Oracle Corporation, 2007. All rights reserved.

233

10. Examine the error message closely, and you will see that it states the following:
Unable to find component with absolute reference =
/oracle/apps/ak/solution/lov/webui/EmpNameLovRN
11. In assembling the components, it was not obvious from the About this Page that
the page contained an LOV. So, it was not assembled as part of our
development copy.
Step 2.6: Fix the Missing LOV
1. Exit JDeveloper.
2. Open a terminal window.
3. Create the directory structures for your LOV files.
mkdir p myprojects/oracle/apps/ak/solution/lov/webui
mkdir p myclasses/oracle/apps/ak/solution/lov/webui
4. Copy the LOV files:
From:

/home/nxuser1/jdevhome/jdev/myprojects/oracle/
apps/ak/solution/lov/webui/*.*

To:

/home/nxuser1/jdevhome2/jdev/myprojects/oracle/
apps/ak/solution/lov/webui/

Copyright Oracle Corporation, 2007. All rights reserved.

234

Step 2.7: Start JDeveloper and Test


1. Start JDeveloper.
2. You should now see the oracle.apps.ak.solution.lov.webui package
added to your Applications Navigator panel.
3. Run QueryPG to test.
4. The page should work properly.
5. Enter B in the Employee Name field, and click the Go button. Your page should
look similar to the following:

Congratulations! You are now finished with this lab.

Copyright Oracle Corporation, 2007. All rights reserved.

235

Supplemental Lab 1

Copyright Oracle Corporation, 2007. All rights reserved.

236

Task 1: Create a new responsibility for iExpenses

1. Log into Oracle Applications with user name SYSADMIN and password
SYSADMIN. Your instructor will provide you with the URL to login to the
E-Business Suite instance assigned to your class.
2. Select the System Administrator responsibility.
3. Select Security: Responsibility > Define from the Navigator.
4. Create a new Responsibility with the following values. Replace XXX with your
terminal number as noted above.

Responsibility Name: XXX_iExpenses

Application: Payables

Responsibility Key: XXX_IEXPENSE

Available from radio button: Oracle Self Service Web Applications

Data Group Name: Standard

Data Group Application: Payables


Copyright Oracle Corporation, 2007. All rights reserved.

237

Menu: Expenses Main Menu

Securing Attributes: ICX_HR_PERSON_ID (Oracle iProcurement).


Everything else can be left blank.

Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

238

Task 2: Create a new responsibility for Manager Self Service

2. Create a new Responsibility with the following values.

Responsibility Name: XXX Manager Self Service

Application: Human Resources

Responsibility Key: XXX_MGR_SELFSERVE

Available from radio button: Oracle Self Service Web Applications

Data Group Name: Standard

Data Group Application: Human Resources

Menu: Manager Self Service (Note: No hyphen in Self Service.) Everything


else can be left blank.

Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

239

Task 3: Create a new responsibility for iProcurement


2. Create a new Responsibility with the following values. Replace XXX with your
terminal number as noted above.

Responsibility Name: XXX iProcurement

Application: Oracle iProcurement

Responsibility Key: XXX_IPROCUREMENT

Available from radio button: Oracle Self Service Web Applications

Data Group Name: Standard

Data Group Application: Oracle iProcurement

Menu: Internet Procurement Home

Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

240

Task 4: Create Your User

Create your own username that you will use for most of the following labs. Navigate to
Security: User > Define.
1. Create a new user with the following values.

User Name: XXX_USER

Password: WELCOME (re-enter to verify)

Password Expiration: None

Person: Stock, Ms. Pat (Note: To put this Person into the field, type Stock
into the field, and then press the TAB key. A pop-up will open allowing you to
select Pat Stock. There may be several Pat Stocks in the instance. You need
to select the one that is employee number 24. Accept the error/warning you
get when associating Pat with your new user because this person is
associated with several user names.)

2. Assign the following responsibilities to your user:

Application Developer

Functional Administrator
Copyright Oracle Corporation, 2007. All rights reserved.

241

System Administrator

System Administration

Preferences SSWA

XXX_iExpenses

iExpenses

XXX Manager Self Service

Manager Self Service V3

Sourcing Super User

iProcurement

XXX iProcurement

Customizing Look and Feel Administrator

OA Framework ToolBox Tutorial Labs

OA Framework ToolBox Tutorial

3. Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

242

Task 5: Test your own User


1. Close the form, and return to the Personal Home Page.
2. Click the Logout link at the top of the Personal Home Page.
3. Return to the login page.

4. Use your new login and password (WELCOME) to log in again. You will be
prompted to change your password.

5. Your new password is:

_________________________________

6. Verify that you have the correct Responsibilities displayed.

Copyright Oracle Corporation, 2007. All rights reserved.

243

Copyright Oracle Corporation, 2007. All rights reserved.

244

Task 6: Create User-level Personalizations


In this section, you will create user-level personalizations as an end user. Anyone with
access to a page that allows saved searches can create user-level personalizations.
1. Return to the Personal Home Page by selecting the Home link at the top of the
page.
2. Select your XXX iExpenses responsibility.

3. Navigate to the Expense Reports page, and select the Expense Reports subtab.

Copyright Oracle Corporation, 2007. All rights reserved.

245

4. Complete the following query steps:

Select the Advanced Search button to bring up the Advanced Search


page.

Select the Show table data when all conditions are met radio button.

Enter criteria for the Report Date field. Set the drop-down box as before.
Set the date as 31-Dec-2000.

Copyright Oracle Corporation, 2007. All rights reserved.

246

Select the Go button.

Copyright Oracle Corporation, 2007. All rights reserved.

247

5. Note which columns are present in the table, and how many rows the table
displays.
6. Select the Save Search button to begin the User Personalization UI.

Copyright Oracle Corporation, 2007. All rights reserved.

248

7. Set the View Name to XXX Reports before Dec. 31, 2000.
8. Set the Number of Rows Displayed to 25 Rows.
9. Remove the Report Submit Date and the Report Status columns. (Note: You
cant reorder the columns in the Expense Reports page, and you cant remove
certain columns.)
10. Select the Rename Columns/Totaling button. Change the name of the Name
column to Submitter Name.

Copyright Oracle Corporation, 2007. All rights reserved.

249

11. Scroll to the bottom of the page, and select Apply.


12. Select Apply and View Results button. You should see your results in your new
layout, including the Submitter Name column and without the Report Status
column. Only records dated before 31-Dec-2000 should be displayed.

Copyright Oracle Corporation, 2007. All rights reserved.

250

Task 7: Duplicate Your User-level personalization


1. Select the Personalize button. (Note: It is located to the right of the View Name.)

2. Duplicate your first saved search by selecting the Duplicate button.

3. Change the View Name to XXX Year 2002 Report.

Copyright Oracle Corporation, 2007. All rights reserved.

251

4. Set the Report Date to after 31-Dec-2001.

5. Set the Add Another field to Report Date, and click the Add button.
6. Set the new Report Date to before 01-Jan-2003.
7. Select the Apply and View Results button.
8. You should see your results in your new layout.

Copyright Oracle Corporation, 2007. All rights reserved.

252

Copyright Oracle Corporation, 2007. All rights reserved.

253

Supplemental Lab 2

Copyright Oracle Corporation, 2007. All rights reserved.

254

Task 1: Create a new responsibility for Sales


1. Login as your XXX_USER choosing the System Administrator responsibility, and
navigate to Security: Responsibility > Define. Create a new responsibility as
follows:

Responsibility Name: XXX Sales User

Application: Sales

Responsibility Key: XXX_SALES_USER

Available from radio button: Oracle Self Service Web Applications

Data Group Name: Standard

Data Group Application: Sales

Menu: ASN_MAIN_MENU

Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

255

Task 2: Add the XXX Sales User responsibility to LJONES user


You will use the LJONES user in a later section of the lab.
1. Go to the Define Users form, and query the user LJONES.
2. Add the XXX Sales User responsibility to LJONES.
3. Save your work.

Copyright Oracle Corporation, 2007. All rights reserved.

256

Task 3: Configure the Configurable Page


In this task, you will personalize a configurable page. Configurable pages are specially
built application pages that allow you to move content around the page, hide and
display content regions, and personalize them to some extent. Note that you cannot
add your own new regions to configurable pages, only regions (and views, if available)
that have been predefined by the developer.
1. Log in as LJONES/WELCOME.
2. Select the XXX Sales User responsibility.

3. Examine the original layout of the Sales Dashboard. Take note of the location of
the Sales Funnel and other regions.
4. Select the Personalize Page link. This page has been built as a configurable
page, so it has a different personalization UI than other pages. It displays two
subtabs, Layout and Content. It also presents a graphical view of the page
hierarchy of regions (containers) in the Layout subtab.
5. Verify that you see the XXX Sales User responsibility for the Personalization
Level field.

Copyright Oracle Corporation, 2007. All rights reserved.

257

Copyright Oracle Corporation, 2007. All rights reserved.

258

6. The Content subtab shows the arrangement of fields and other page content.

Copyright Oracle Corporation, 2007. All rights reserved.

259

7. Select the Layout subtab.


8. Change the Sales Funnel and Calendar & Tasks region to a horizontal layout
by clicking the horizontal layout icon within the region.

Copyright Oracle Corporation, 2007. All rights reserved.

260

9. Change the order of the Sales Funnel and the Calendar & Tasks region by
clicking on the reorder icon. Move Calendar and Tasks before Sales Funnel at
the Responsibility level.

10. Select the Apply button.

11. Remove the Shortcuts and Latest Submitted Forecast region from the layout
by clicking on the remove icon on that region. When you do, you will receive a
delete warning page.

Copyright Oracle Corporation, 2007. All rights reserved.

261

12. When you removed the Shortcuts and Latest Submitted Forecast region from
the page, you encountered a quirk of the configurable page layout. Notice that
the Calendar & Tasks and Sales Funnel region has reverted to vertical layout.
Just prior to region removal, the region was in horizontal layout. Also, the parent
container region for Calendar/Funnel and Shortcuts/Forecasts was removed.
Change the Calendar & Tasks and Sales Funnel region back to horizontal
layout.
13. Add a column to the parent container by clicking on the Add Column icon. When
you add the column, it is in the layout, but it does not yet have any contents. You
will do that from the Content subtab.

Copyright Oracle Corporation, 2007. All rights reserved.

262

Copyright Oracle Corporation, 2007. All rights reserved.

263

14. Select the Content subtab.

15. Add content to your newly added column by clicking the Add Content icon on
the region where you want to add that content.

Copyright Oracle Corporation, 2007. All rights reserved.

264

16. You only have 2 choices of predefined content that is not already on the page,
Top Customers and Top Opportunities. Add both to the region.

17. Select the Apply button.

Copyright Oracle Corporation, 2007. All rights reserved.

265

18. Add a border around a container by selecting the Personalize icon (pencil) for
the container and setting the Flexible Content: Sales Funnels personalization
properties. Set the Show Border property to true.

19. Select the Apply button.

Copyright Oracle Corporation, 2007. All rights reserved.

266

20. Select the Return to Application link. NOTE: You may need to click the
browsers RELOAD PAGE icon to get the page to display properly.

21. Verify that the page looks similar to the changes shown.

Copyright Oracle Corporation, 2007. All rights reserved.

267

Supplemental Lab 3

Copyright Oracle Corporation, 2007. All rights reserved.

268

Task 1: Use SPEL Syntax in Your Personalizations


1. Select your XXX Manager Self Service responsibility from the Personal Home
Page.
2. Select the Change Hours page.
3. Select the Action icon for any of the names listed in the table.

4. Select the Continue button on the Change Hours: Effective Date Options
page to skip through it.
5. On the Change Hours: Work Schedule page, verify that you can enter the
Work Hours field and change its value. This is the starting state.
6. Select the Personalize Page link.
7. Find the Message Text Input: Work Hours item.
8. Select the Personalize icon.
9. Select the Choose Levels Displayed button.
10. Select only the Responsibility level to be displayed.
11. Click the Apply button.
12. Personalize the Read Only property by selecting SPEL from the dropdown list of
values. Then type in the following expression: (Note: Replace XXX with your
student number.)
Copyright Oracle Corporation, 2007. All rights reserved.

269

${oa.FunctionSecurity.XXXWORKHOURSREADONLY}
13. Click the Apply button.
14. Select the Return to Application link.
15. Verify the Work Hours field should be shown as a read-only field. This is the
read only state (the user does not have access to the function you specified).

16. Select the Home link at the top of the page.


17. Select the System Administrator responsibility from the Personal Home Page,
and navigate to Application > Function.
18. Set the Function to XXXWORKHOURSREADONLY.
19. Set the User Function Name to XXX Work Hours Read Only.
20. Select the Properties tab.
21. Set the Type to Subfunction.

Copyright Oracle Corporation, 2007. All rights reserved.

270

22. Save your work.


23. In the same forms-based responsibility, navigate to Application > Menu.
24. Select the Functional Administrator responsibility.
25. Query for the Menu called HR_LINE_MANAGER_ACCESS_V4.0.
26. Add a row to the menu.
27. Set the Seq to 99.
28. Leave the Prompt and Submenu fields empty
Copyright Oracle Corporation, 2007. All rights reserved.

271

29. Set the Function to XXX Work Hours Read Only

30. Save your work.


31. When you save, a concurrent request to recompile your menu will be submitted
to your E-Business Suite instance. Menu changes will not occur until your menu
recompiles, and the global cache is flushed. To force clearing the global cache,
navigate to Functional Administrator: Core Services > Caching Framework >
Global Configuration, and click the Clear All Cache button. Click Yes on the
Warning page.
32. Exit the Forms-based responsibility, and return to the Personal Home Page.
33. Select the XXX Manager Self Service responsibility.
34. Select the Change Hours page.
35. Select the Action icon for any of the names listed in the table.
36. Select the Continue button on the Change Hours: Effective Date Options
page to skip through it.
37. On the Change Hours: Work Schedule page, verify that you can enter the
Work Hours field and change its value. This is the ending state, which looks
exactly like the starting state. At least it does, for this responsibility.

Copyright Oracle Corporation, 2007. All rights reserved.

272

Copyright Oracle Corporation, 2007. All rights reserved.

273

Task 2: Extending an Existing Region into a Page


You must create your region in such a way that you can personalize it later to appear
only for your own responsibility. So you must first create a stack layout region to hold
the flexible layout region and its flexible content region.
1. Go to the Personal Home Page.
2. Select your XXX_iExpenses responsibility.
3. Select the Personalize Page link.
4. Select Complete View.
5. For the Page Layout: Expenses Home region, select the Create Item icon.
6. Set the Level to Site.
7. Set the Item Style to Stack Layout.
8. Set the ID to XXX_StackLayout.
9. Set the CSS Class to OraNav3Enabled.

10. Select the Apply button.


11. Select the Create Item icon for your new stack layout region.

12. Set the Level to Site.

Copyright Oracle Corporation, 2007. All rights reserved.

274

13. Set the Style to Flexible Layout.


14. Set the ID to XXX_FlexibleLayout.
15. Select the Apply button.
16. Select the Create Item icon for your new flexible layout region.
17. Set the Level to Site.
18. Set the Style to Flexible Content.
19. Set the ID to XXX_FlexibleContent.
20. Set the Extends property to the name that you got from the analyzing the
Favorites region.
/oracle/apps/fnd/framework/favorites/webui/FavoritesRG
Note: While you added the Favorite shared region to the page, you could just as
easily add any other shared region to your page. For sake of the exercise, this was a
convenient shared region to add.
21. Select the Apply button.
22. Personalize your stack layout region so your regions appear only for your own
responsibility. Select the Personalize icon.

23. Select the Choose Levels Displayed button.


24. Select just the Site and Responsibility levels to be displayed.
25. Click the Apply button.
26. Set the Rendered property at the Site level to false, and at the Responsibility
level to true.
27. Click the Apply button.
28. Select the Reorder icon for the Page Layout: Expenses Home page.
29. Uncheck the checkbox for Function level.
30. Uncheck the checkbox for Site level.

Copyright Oracle Corporation, 2007. All rights reserved.

275

31. Check the checkbox for Responsibility level.


32. Reorder your regions so the Favorites region appears at the top of the page.
Note that the page-level buttons will still appear above your Favorites region,
even though you reordered the stack layout to the top position. This is because
the Page Button Bar region style has specific behavior built in to put the buttons
at the top and bottom of the page (similar to the fixed behaviors/locations of the
copyright, corporate branding and so on).
33. Click the Apply button.
34. Select the Return to Application link.

35. Return to the Expenses Home page and look at your new region.

Copyright Oracle Corporation, 2007. All rights reserved.

276

Task 3: Add a Region Using Url Include


In this task we will add a new region to the Expenses Home page. The URL will point to
http://<servername>/OA_HTML/AnnouncementTest.html, which is a region written in
simple HTML. For convenience of the task, you are using this page, but it could just as
easily be a page deployed on your E-Business Suite instance that is unique to your
company and its announcements.
1. Return to the Expenses Home page using your XXX_iExpenses responsibility.
2. Select the Personalize Page link.
3. Using the Complete View layout, select Create Item for the Page Layout:
Expenses Home region.
4. Set the Level to Site.
5. Select the Url Include for the Item Style.
6. Set the ID to XXX_Announcements.
7. Set the Source URI to
http://<servername>/OA_HTML/AnnouncementTest.html.
Note: You will have to point to the server you have been using for your class.
8. Select the Apply button.
9. Personalize your new item so your announcements appear only for your own
responsibility. Select the Personalize icon.
10. Select the Choose Levels Displayed button.
11. Select just the Site and Responsibility levels to be displayed.
12. Click the Apply button.
13. Set the Rendered property at the Site level to false, and at the Responsibility
level to true.
14. Select the Apply button.
15. Select the Reorder icon for the Page Layout: Expenses Home page.
16. Uncheck the checkbox for Function level.
17. Uncheck the checkbox for Site level.

Copyright Oracle Corporation, 2007. All rights reserved.

277

18. Check the checkbox for Responsibility level.


19. Reorder your regions so the Announcements section appears first.
20. Select the Apply button.
21. Select the Return to Application link.
22. Verify your personalization.

Copyright Oracle Corporation, 2007. All rights reserved.

278

Das könnte Ihnen auch gefallen