Monday, 4 February 2013

Create Data Entry Form in ADF

1. Create a New Application
File > New > Applications > Fusion Web Application (ADF)
Application Name – DataEntryApplication
Directory -- (Jdev install dir)/jdeveloper/(project name)
Application Package Prefix – Demo.adf.DataEntryApp




2. We need to have table where Data will be saved. Lets Create a table
     CREATE TABLE data_entry_test
     (     Column1   VARCHAR2(100),
           Column2   VARCHAR2(100)

3. Create EO for Page (Entity Object)
Right Click on Model > New > ADF Business Components > Entity Object
Package -- Demo.adf.DataEntryApp.model
Name – DataEntryEO
Schema Object – DATA_ENTRY_TEST



Note – By default ROWID will be the primary key if we will not make any column to be primary key in Attribute Setting Page
Check the Accessors, Create Method, and Remove Method

Check “Generate Default View Object CheckBox”
Package – Demo.adf.DataEntryApp.model.queries
Name – DataEntryVO
Check “Application Module” Checkbox
Package –
Name – DataEntryAM


4. Create JSF Page for Data Entry Page
Create a JSF Page
Right Click on ViewController > New > Web Tier > JSF > JSF Page
File Name – DataEntry.jspx
Initial Page Layout and Content – Quick Start Layout
Expand Page Implementation region and select Automatically Expose UI Components in a New Managed Bean

Select DataControls > DataEntryAMDataControl > DataEntryVO1 and drag to jspx page and choose Form > ADF Form. Choose the fields as shown in the slide

Remove RowID row

5. Add Commit and Create Operations in Page
Select DataControls > DataEntryAMDataControl > Operations
Drag Commit Operation in page
Similarly Select DataControls > DataEntryAMDataControl > DataEntryVO1 > Operations
Drag Create Operation in page

Select option ADF Button

6. Select Commit button and make field Disabled in properties to be NULL

7. Congratulation you have successfully finished Data Entry ADF Form. Test Your Work

Click on Create Button

Enter Data and Click Commit Button

Check backend table

1 comment:

  1. Hello
    I am very happy with you for this tutorial
    only the images are heavy impossible to see
    thank you

    help me to have in pdf format by me email.
    I am a beginner in oracle ADF