Showing posts with label OAF Extensions. Show all posts
Showing posts with label OAF Extensions. Show all posts

Friday, 30 March 2018

OAF VO Extension : How to add new Column in the Expense Report Summary Home Page

OAF VO Extension : How to add new Column in the Expense Report Summary Home Page

In this post , we will do View Object VO extension in Oracle Application OAF web pages. first of all , we will discuss the need of the VO extension in OAF. When we have an requirement to display some more attributes or fields in the OAF page then we do VO extension to meet this requirement. We all know that , We see the data in the OAF page through View Objects(VO) and in a single page can have more then 1 View Objects(VO). First of all , we need to find out that , in which Standard View object , we need to add new Fields in OAF Page. Then we do view Extension , to add this new field in the View Object and then display this new Field in the OAF page through Personalizations.
 

VO Extension Steps:-

1.Indentify that Which VO we need to Extend
2. Download the VO from Oracle Java_Top Location to Your Local Desktop under My Projects folder of Your JDev setup.
3.Then We create New view Object(VO) which extends the Standard View Object.
4.Then We substitute the New Custom View Object with the Standard View Object.
5.Then we upload the New Custom View Object to Oracle Java_Top Location.
6.Then we Register the New View Object in the Oracle application Through XML Importer script.
8.After Import/Register , We add the new field in the OAF page through Personalization and then give reference in this Field for the New Custom View Object(VO).
 

OAF VO Extension Example: How to add new Column in the Expense Report Summary Home Page

 
Step1:- First Go to your OAF page in the application , in which you will do View Object Extension.
This is the Page in which we will do View Extension. Here I want to display the DFF attribute5 in this Track Submitted Expense Reports Status Window.
 
OAF VO Extension : How to add new Column in the Expense Report Summary Home Page

 
 
Step2:- To see the Properties of this Page and to know which View Object is working behind this Page. for this we need to go to 'About this Page' in the Bottom of the Page.
 
 
 
Step3:- Click on the Expand All option and in the Controller Section you can see the Controller Name
 
OAF VO Extension : How to add new Column in the Expense Report Summary Home Page
 
 
 
Step4:-Click '+' icon for Business Components References Details.
 
OAF VO Extension
 
 
Step5:- This is the Location of the View Object under Java_Top under which you will do Extension.
 
OAF VO Extension
 
Step6:-
 
 Now you get to know that where is your Standard View Object is Placed in the Oracle application Under Java_Top.

Then you Need to go to Server Under Java_Top then Under Java_Top follow the same path 'oracle/apps/ap/oie/webui/' and copy the 'TrackExpesneReportsVO' from Server to your Local Desktop.

One Important Thing.

You need to create the same path in your JDev folder under' 'jdevhome'
Under JdevHome there is MyProjects' folder under this folder you have to Create same folder structure like oracle/apps/ap/oie/server/' and then this copied file 'TrackExpesneReportsVO' in this Location.

The rule is you have to create same folder structure like the Folder Structure created for The Standard Controller in the Application server Java_Top.
 
OAF VO Extension
 
 
Step6:-This is the steps you have to implement before doing Start Extension in the JDeveloper.
 
Step7:- Now open the JDeveloper.
 
OAF VO Extension
 
 
 
 
Step8:- Now we will create OA Workspace and Project to do Controller Extensions.
 

OAF VO Extension
 
Step9:- Give the Name of OA Workspace. Click Ok.
OAF VO Extension
 
 
Step10:- Now Give the Name of the Project same like OA workspace.
Package Path:- Choose the same like Standard View Object but choose the application Top start with xx like this this change 'xxap'.
OAF VO Extension
 

Step11:- Then Finish this Project.
Controller Extension In OAF :How to add OAF code in Controller Extension on Button Click Event

Step12:- Now you can see your OAF Project has been completed. Now we will do Controller Extension under this Project.
OAF VO Extension



Due to the Length of this Topic , I will split this Topic two Posts. Please find the Second Part of this Post as below

Part2 url:- https://rpforacle.blogspot.in/2018/03/oaf-vo-extension-how-to-add-new-column-in-the-expense-report-summary-home-page.html



OAF VO Extension : How to add new Column in the Expense Report Summary Home Page

Friday, 23 March 2018

Controller Extension In OAF :How to add OAF code in Controller Extension on Button Click Event

Part1 Controller Extension In OAF :How to add code in Controller Extension on Button Click Event

 
We will do today controller Extension in Oracle Application OAF pages. We need Controller Extension when we want to add custom Validations and to add extra monitoring in the Standard process or to Control the Standard Page behavior  then we do Controller Extensions to achieved this requirement. We can control the functionality of the Page through Controller codes and if we want to control the Standard OAF pages then we do OAF Controller Extensions.
 
Test Case:- In this example , I will do Controller Extension in the Expense Reports Home Page. Suppose your Business requirement is  that When ever user will withdraw his expense report then it will create history in the Custom table that how many times this particular Expense Report's  Withdraw and on which date. So lets start to do this.
 

Controller Extension In OAF :How to add code in Controller Extension on Button Click Event

 
Step1:- First Go to your OAF page in the application , in which you will Controller Extension.
This is the Page in which we will do Controller Extension. you can see the Withdraw button in the Right side of the Page for Every Report.
 
Controller Extension In OAF :How to add OAF code in Controller Extension on Button Click Event
 
 
Step2:- To see the Properties of this Page and to know which controller is working behind this Page. for this we need to go to 'About this Page' in the Bottom of the Page.
 
 
 
Step3:- Click on the Expand All option and in the Controller Section you can see the Controller Name.
 
Controller Extension In OAF :How to add OAF code in Controller Extension on Button Click Event
 
 
 

Step4:- Now you know the Controller Name but you also need to get  the Location of the Controller in Oracle Application to so Controller Extension.


Step by Step to do Controller Extension

This is the Location of the Controller under Java_Top under which you will do Extension.
OAF Extension Guide

Step5:- Now you get to know that where is your Standard Controller is Placed in the Oracle application Under Java_Top.

Then you Need to go to Server Under Java_Top then Under Java_Top follow the same path 'oracle/apps/ap/oie/webui/' and copy the 'TrackExpesneReportsCO' from Server to your Local Desktop.

One Important Thing.

You need to create the same path in your JDev folder under' 'jdevhome'
Under JdevHome there is MyProjects' folder under this folder you have to Create same folder structure like oracle/apps/ap/oie/webui/' and then this copied file 'TrackExpesneReportsCO' in this Location.

The rule is you have to create same folder structure like the Folder Structure created for The Standard Controller in the Application server Java_Top.

 
 
 
Step6:-This is the steps you have to implement before doing Start Extension in the JDeveloper.
 
Step7:- Now open the JDeveloper.
 
 
 
 
 
Step8:- Now we will create OA Workspace and Project to do Controller Extensions.
 

 
Step9:- Give the Name of OA Workspace. Click Ok.
 
 
Step10:- Now Give the Name of the Project same like OA workspace.
Package Path:- Choose the same like Standard Controller but choose the application Top start with xx like this this change 'xxap'.
 

Step11:- Then Finish this Project.
Controller Extension In OAF :How to add OAF code in Controller Extension on Button Click Event

Step12:- Now you can see your OAF Project has been completed. Now we will do Controller Extension under this Project.
 Due to the Length of this Topic , I will split this Topic two Posts. Please find the Second Part of this Post as below

Part2 url:- https://rpforacle.blogspot.in/2018/03/oaf-controller-extension-in-oaf-how-to-add-oaf-code-in-controller-extension-on-button-click-event.html


 

Thursday, 22 March 2018

How to Execute and Fetch SQL Queries Data Rows in OAF

How to Execute and Fetch SQL Queries Data in OAF

 
Hi Friends , In this post I will show the OAF code to Execute the Sql query in the OAF controller and then Fetch all the rows of this queries in the Same controller to do further Analysis. We often need to user SQL queries in OAF code to do data comparison and to get the values from other modules so using this OAF code will help you allot in you OAF controller Extension to execute and fetch all the rows of the Sql query.
 

How to Execute and Fetch SQL Queries rows in OAF

 
Step1:- Suppose you are doing Controller Extension in your PR approval Notification Page and in your PR you have maintained some values in DFF of 'PO_REQUISITION_LINES_ALL' and here in CO extension you want to fetch these values.
 
 
Step2:-  This is the OAF code to execute and Fetch Sql query results in OAF controller and then can be used for Comparison.
 
 
 public void processRequest(OAPageContext paramOAPageContext, OAWebBean paramOAWebBean)
    {
      paramOAPageContext.writeDiagnostics(this, "XX Start PR ", 1);
     
        String parameterName;
        String COL1_VALUE="";    
        String COL2_VALUE=""; 
        String COL3_VALUE="";    
       
       Number PRHdrId;
            PRHdrId = new Number(paramOAPageContext.getDecryptedParameter("PRHeaderId"));
                if (PRHdrId!=null)
                {
        
    Connection conn = paramOAPageContext.getApplicationModule(paramOAWebBean).getOADBTransaction().getJdbcConnection();
     String Query = "SELECT attribute1 col1,attribute2 col2,attribute3 col3 FROM PO_REQUISITION_LINES_ALL WHERE REQUISITION_HEADER_ID=TO_NUMBER(:1)";

                PreparedStatement stmt = conn.prepareStatement(Query);
                   String PRHdrId = ""+PRHdrId;
                   
     stmt.setString(1,PRHdrId);
     for(ResultSet resultset = stmt.executeQuery(); resultset.next();)
     {
  
   COL1_VALUE = resultset.getString("COL1");
                       COL2_VALUE = resultset.getString("COL2");
                       COL3_VALUE = resultset.getString("COL3");
      paramOAPageContext.writeDiagnostics(this, "Query executed"+COL1_VALUE,1);
                   paramOAPageContext.writeDiagnostics(this, "Query executed"+COL1_VALUE,1);
                   paramOAPageContext.writeDiagnostics(this, "Query executed"+COL1_VALUE,1);
     }
  
 
 
Result Set :-
 
A table of data representing a database result set, which is usually generated by executing a statement that queries the database.
A ResultSet object maintains a cursor pointing to its current row of data. Initially the cursor is positioned before the first row. The next method moves the cursor to the next row, and because it returns false when there are no more rows in the ResultSet object, it can be used in a while loop to iterate through the result set.
 
 
 
How to Execute and Fetch SQL Queries Data Rows in OAF
 
 
How to Execute and Fetch SQL Queries Data Rows in OAF

Wednesday, 21 March 2018

How To Get the LOV Selection Event in OAF Controller For CO Extension

How To Get the LOV Selection Event in OAF Controller For CO Extension

We often need in OAF Controller Extensions to get the Events from the Page to Execute our Custom Code. Suppose If we want to Execute or want to Change some values in the OAF page when the user will select the LOV from the OAF page. For this We can use this below code to Find the LOV Selection Event in the OAF controller and write our custom code inside that Event for Controller(CO) Extension.
 
How To Get the LOV Selection Event in OAF Controller For CO Extension
 

How To Get the LOV Selection Event in OAF Controller For CO Extension

There are two ways by which you can get the LOV selection event in the OAF page.
 
1.pageContext.getLovInputSourceId()
2.pageContext.getParameter(SOURCE_PARAM)
 
 
You can write your Code in the Process Form Request of your CO Extension in this manner
 
You should know the name of your LOV Item in your OAF page so that you can compare this Name with all the Lov selection events in the OAF page because it could be possible there are more then 1 LOV's in the OAF page so you have to distinguish for which LOV selection you want to execute your custom code. 
 
if(pageContext.isLovEvent())
 
  {
String lovInputSourceId = pageContext.getLovInputSourceId();
  if("Country".equals(lovInputSourceId))
{
System.out.println("You can write your Customer Code inside this");
paramOAPageContext.writeDiagnostics(this, "LOV Selection ", 2);
 }
 } 
 

How to Compare the LOV selected value by user in the OAF Page.

 
 if(pageContext.isLovEvent()) 
 {  
      String lovInputSourceId = pageContext.getLovInputSourceId(); 

      if("Country".equals(lovInputSourceId)) {
      paramOAPageContext.writeDiagnostics(this, "LOV Selection ", 2);
           Hashtable lovResults = pageContext.getLovResultsFromSession(lovInputSourceId); 
           if(lovResults!=null) 
           { 
                String Country1 =(String)lovResults.get("Country"); // "Country" is the Return Item specified in the lovMap  

           paramOAPageContext.writeDiagnostics(this, "Selected Country "+Country1);
 
 
 
This code is used to do comparison with the LOV selected value in the OAF Page in CO Extension
 
 
How To Get the LOV Selection Event in OAF Controller For CO Extension
 



 

Wednesday, 10 January 2018

Part 2- How we can attach custom LOV in Oracle Standard OAF Page Without doing any customization and extension in standard OAF Page.


This is our Supplier Creation Page where I want to see Custom LOV of External Supplier No so that user can select that Number during supplier creation in Oracle.

 
First of all we get to know which VO object is working behind this suppler creation page for this you need to click on About this page and then expand all.
You need to search with Supplier form any field to get the VO working for that fields. In our case we got that HzPuiOrganizationProfileQuickVO is working on supplier page.
 
 
 
Click on Personalize ‘Organization Quick code link in Supplier Page
Click on Create Item as below.
 
Select Level – Site and Item Style – Message Lov Input.
ID= Any name you can give without spaces.
External LOV- Path of your Custom VO which you create in Jdev.
/oracle/apps/apexp/RohitExternalLOV/server/RohitExternalLOVVO.
Prompt:- External Supplier No.
View Attribute = Attribute2 (DFF Field)
View Instance = HzPuiOrganizationProfileQuickVO
 
 
 
 

Now again under External Supplier No LOV input field è click on create item for Lov mappings.

 
 
 
 
Level =Site
Item Style= Lov Map
ID= Any Id without space
Criteria Item= ExternalSupplierNo ( LOV item created in JDev)
LOV Region Item= RohitExternalLOV (LOV Region name created in JDeveloper)
Return Item = XX_EXTERNAL_SUPPLIER( LOV Input item created in OAF page by personalization in previous step)
 
 
 
LOV Region Item
 
 
Criteria Item
 
 
 
 
After the personalization we can see below , External Supplier No is started showing in the Supplier Creation Form in Oracle Standard OAF page.
 
 

Sunday, 10 March 2013

OAF TUTORIAL :OA Framework(OAF) Learning Tutorial

OAF TUTORIAL : OA Framework(OAF) Learning Tutorial

OAF Represents Oracle Application Framework. OAF is the new technology which is Implemented in the Oracle r12. OAF help use to design the complete Web based forms , earlier in the Oracle 11i this was not feasible and we need to have run time java software to run these forms but in the OAF web pages we don't need these java software and the good part is we can also run the OAF pages in the Mobiles and the Tablets also. The purpose of this OAF Tutorial is the share the free Knowledge of this technology with the Oracle Community. This is the complete Set by step Tutorial , Which can be even refer by the beginners in the OAF and can also refer by the OAF experts too. I have increased the Post difficulty step by step in this Tutorial. I have Started this Tutorial with the Introduction of the OAF then go to Installation of the JDev software to start work on the OAF.
OAF TUTORIAL
OAF TUTORIAL

You will get the complete material of OA Framework(OAF) Learning Tutorial. You can refer this blog as Learning Tutorial to start your Journey in the Oracle OA Framework(OAF). I have shared Step by Step for the each Technical topic of OA Framework(OAF). This is a complete OA Framework(OAF) Learning Tutorial.

OAF Tutorial Lessons:


2.    JDeveloper Installation

3.    Creating Simple Hello world in OAF

4.    How we assign default values in the OAF Page

5.    Creating POP List (List Item) in OAF Page

6.    Part1 Creating LOV in OAF Page

6.    Part2 Creating LOV in OAF Page

7.    Understanding about Page layouts in OAF

8.    How we create a dependent LOV in OAF

9.    Create a data Entry Page in OAF

10.    Updates Records in OAF Page

11.  Delete Records in OAF Page

12.  Calling OAF Page from another OAF Page

13.  Creating OAF Search Page

14(a).  OAF VO Extension : How to add new Column in the Expense Report Summary Home Page

14(b).Part 2 OAF VO Extension : How to add new Column in the Expense Report Summary Home Page

15 (a). Part 1 Controller Extension In OAF :How to add code in Controller Extension on Button Click Event

15(b). Part 2 Controller Extension In OAF :How to add code in Controller Extension on Button Click Event

16. Partial rendering in OAF Page(Conditional Displaying Any Item)

17. Package/Procedure Using in OAF Page

18.Upload File In Oracle Server from Local Machine In OAF Page

19.Dynamic Color change in OA Framework  

20.SPEL In OA Framework Personalizations.

21. Part 1- How we can attach custom LOV in Oracle Standard OAF Page Without doing any customization and extension in standard OAF Page

22. Part 2- How we can attach custom LOV in Oracle Standard OAF Page Without doing any customization and extension in standard OAF Page

P2P Complete Cycle(Configuration & End to End Process) In Oracle Fusion


23.How to Create Dynamic LOV in OAF Through Controller Extension
24.Trigger|Execute Custom Code Based on value Selected in LOV in Standard OAF Page
25.How to get the Name of all Objects and their Run time Value in Running OAF page to use in the controller Extension
26.How to Change Where Condition for View Object (VO) in OAF Technology
27.How to check the Value of View Object(VO) all Columns during Run Time of OAF Page.
28.OAF Important Scripts To Verify and Delete the OAF Extensions from Oracle application.
29.How to Execute and Fetch SQL Queries Data in OAF
30.How to Debug and See Log Messages in OAF Pages
31.How To Get the LOV Selection Event in OAF Controller For CO Extension
32.How to Integrate Java Decompiler with J Developer in OAF
33.How to Create Button in OAF Page Programmatically or Dynamic
34.How to Create Events in OAF Page Programmatically Through Controller Extension
35.Assigning Values to the DFF attributes through SQL query in OAF Page through Controller Extension
36.How to do VO Extension in OAF Through controller Extension: Add New column to Standard VO through Controller Extension
37.Table layout region in OAF. Table region in oaf
38.Types of search pages in OAF
39.Difference between auto customization criteria and result based search in oaf
40.Auto Customization Criteria in OAF
41.What is Root AM in OAF
42.Why can't root AM be extended in OAF
43.Result Based Search in OAF
44.Query Bean in OAF. How to Create Query Bean Search page in OAF
45.Advanced Search Region in OAF. Advanced Search Page in OAF
46.Application Module in OAF.How to attach VO to AM in OAF
47.Entity object in OAF. How to create EO in OAF
48.Exception handling in OAF
49.Dialog message in oaf. How to display popup message in oaf
50.oaexception in oaf. Display message in oaf page

Oracle Application Interview Questions List

New : TOP 23 Most Important Oracle Fusion Interview Questions
New : TOP 20 general ledger interview questions
New: 21 Most Important Oracle r12 Payables Interview Questions
New : TOP 20 general ledger interview questions in oracle apps r12
New: 25 Most Important Oracle receivable interview questions
TOP 33 Most Important Oracle Apps Technical Interview Questions

OAF Personalizations Examples


1.OAF Personalization :How To show Password Hint Option in Oracle E-Business Suite Login Page that can help users to set their Strong password
2.OAF Personalization : How to Display new Field/column in Supplier Search Page
3.OAF Personalization : How to Change the positions of Column & layout in OAF Page
4.How to Delete and De Activate the OAF Personalization in OAF Pages in Oracle Apps
5.How to Migrate OAF Personalizations from One Instance to Another Instance Automatically.

OAF TUTORIAL

Contact us for any Collaboration, Project Support & On Job Support Work

Name

Email *

Message *