How to Create OAF Search Page in R12.2.X/R12.1.X

How to Create OAF Search Page in R12.2.X/R12.1.X

1. Create a New Workspace and Project

Right click Workspace and click create new OAWorkspace and name it as SimpleSearch. Automatically a new OA Project is also created. Name the project as SimpleSearchPrj and package as xxdcb.oracle.apps.fnd.webui

How to Create OAF Search Page in R12.2.X/R12.1.X



2. Create or Select Design time DB Connection Details.



3. Select Run time Connection Details and Click on Finish 



4. Create a New Application Module (AM)


Right Click on SimpleSearch > New > ADF Business Components > Application Module

Name -- SearchAppAM

Package -- xxdcb.oracle.apps.fnd.server







5. Create a New View Object (VO)


Right click on SimpleSearch > New > ADF Business Components > View Object

Name -- EmployeeVO
Package -- xxdcb.oracle.apps.fnd.server

Query --
           SELECT * FROM fwk_tbx_employees






6. Add  View Object to Root  Application Module


Select Right click on SearchAppAM > Edit SearchAppAM > Data Model >

Select EmployeeVO and shuttle to Data Model list






7. Create a New Page


Right click on SimpleSearch> New > Web Tier > OA Components > Page

Name -- SearchPG
Package -- xxdcb.oracle.apps.fnd.webui




8. Select the SearchPG and go to the structure pane where a default region has been created


set the following properties:

ID -- PageLayoutRN
Region Style -- PageLayout
AM Definition -- xxdcb.oracle.apps.fnd.simplesearch.server.SearchAppAM
Window Title -- Employee Search Page 
Title -- Search Page




10. Add a Query Bean to Your Page


Right click on PageLayoutRN > New > Region

Select new region region1 and set following properties

ID – QueryRN
Region Style –query
Construction Mode – resultBasedSearch
Include Simple Panel – True
Include Views Panel – True
Include Advanced Panel – True





11. Add a Result Data Table to your QueryRN


Select QueryRN right click > New > Region using Wizard

In BC4J Objects page, Select your SearchAppAM and then select your EmployeeVO








12. Set for the Columns what all is required for Search. Here for the Demo, EmployeeId and ManagerId are exposed to search   Item Properties


Search Allowed -- True
Sort Allowed – ascending
Initial Sort Seqence – first
Selective Search Criteria – True




13. Save all Your Changes. Run Your SearchPG page and Test Your Work




No comments