Sie sind auf Seite 1von 49

VO Extension

When we want to add an extra field or column to the existing VO or when we want to add
a where condition i.e. sql query modification

Goto purchasing vision operations Invite a Supplier User

Goto the lov of supplier name

On clicking go
Along with this vendor type lookup code should also come

Now goto personalize supplier table

Click on create item


Give site level,style as message styled text,id as VTypeLookupCode and prompt is
Vendor Type Lookup Code
When you click on go values dont come for vendor type lookup code
So for this we have to do VO extension

There are three ways to identify the VO

Naming convention

Goto about this pageclick on business component reference details which will display
the VOs
By seeing the naming convention , we can identify the VO

For eg. VendorsVO

2) Open the VO and find the attribute names

Click on the vo then we can see the attributes


3)
Download the page from oracle apps application top

Goto Invite a Supplier User

About this page


All the standard pages and regions will be there in the APPL_TOP
All the controllers ,AM,VO ,EO will be there in JAVA_TOP.

Goto the application top

E:\oracle\VIS\apps\apps_st\appl\pos\12.0.0\mds\registration\webui
It is from /oracle/apps/pos/registration/webui/RegSuppUserPG 120.2.12010000.3 which
is in the personalize page of the main page

Copy the page and paste the page in any workspace (RegSuppUserPG.xml)

Open any workspace in my projects folder and paste the page there

E:\p6908968_R12_GENERIC\jdevhome\jdev\myprojects\flex\oracle\apps\po\FlexFieldp
kg\webui
Now the page comes here
See here when you goto region and see the supplier name you can see the view attribute
name which is nothing but the supplier name in the OAF page which we opened

See here supplier region is disabled


This implies that this is an external lov region and in order for this to be enabled we have
to import this region too

2) Download the respective VO from java top and create the same directory structure in
my projects folder of local system

The VO can be identified through the view instance name of the supplier name
attribute through the page downloaded
All VOs will be there in java top so goto

Server

E:\oracle\VIS\apps\apps_st\comn\java\classes\oracle\apps\pos\registration\server

There VendorsVO.xml file will be there.this VO is a view of the external region


For this copy pos
Copy pos to the below local path

E:\p6908968_R12_GENERIC\jdevhome\jdev\myprojects\oracle\apps
3)Now create dummy workspace and project for VO extension
Get the package name from below
Create a new view object in custom BC4J and not in oracle BC4J by right clicking on
server

In order to create directory create a new page


Right click on server new view object
Add the new column vendor lookup code in the query

Select vendor_id, vendor_name, segment1,vendor_type_lookup_code from


PO_VENDORS
where
enabled_flag = 'Y'
and ( START_DATE_ACTIVE is null OR START_DATE_ACTIVE < SYSDATE )
and ( END_DATE_ACTIVE is null OR END_DATE_ACTIVE > SYSDATE ) and
(vendor_type_lookup_code is null or vendor_type_lookup_code <> 'EMPLOYEE')
Rebuild BC4J components

Goto tools project properties business components substitutions


Select the vendors VO file in the available and the extended file in the substitute and
click on add
Click on add
Now right click on jpr and click on rebuild
Move all the respective files to server from my classes folder

From :

E:\p6908968_R12_GENERIC\jdevhome\jdev\myclasses

Copy the custom folder created


Paste the custom folder to

To:
E:\oracle\VIS\apps\apps_st\comn\java\classes
select*fromjdr_pathswheretrunc(creation_date)=trunc(sysdate)
Now run the jpx import script

Open cmd

E:/

CD E:\p6908968_R12_GENERIC\jdevbin\oaext\bin
jpximport E:\p6908968_R12_GENERIC\jdevhome\jdev\myprojects\
VendorVOExtprj.jpx -username apps -password apps -dbconnection "(description =
(address_list = (address =(protocol = tcp)(host =apps.oracle.com)(port = 1521)))
(connect_data = (sid = vis)))"
Now goto purchasing vision operations register a supplier user
Click on the LOV

Click on update item

Give view instance as original VO

And view attribute as view attribute name