Sunday, January 30, 2011

Display JSF Page as email page in Oracle ADF

Hi,

ADF provides a simple way to display page as email page. all you need is to just concat the following to  the current page URL.

org.apache.myfaces.trinidad.agent.email=true

For example if your page name is view1.jspx then following code will display the page as email page on af:goButton component



More info on the documentation.

Have a nice day,
Zeeshan Baig

Friday, January 21, 2011

Working with Attribute level security in Oracle ADF

Hi,

In this video we will see how to work with attribute level security in Oracle ADF.

I will create 2 groups in adf security called admin and basic and only users with group admin can change the salary of an employees table.

Download sample code

Watch the video tutorial




Happy Jdeveloping,
Zeeshan Baig

My presentation Getting started on Oracle APEX

Hi,

I know its late but finally i am uploading my presentation which i presented on Oracle APEX at "Techno-ed" a certified Oracle education partner in Pakistan. It was free sessions conducted by a IT awareness program from PITUG

Click to download

Have a nice day,
Zeeshan Baig

Sunday, January 16, 2011

Drag and Drop Collection in Oracle ADF

Hi,

In this example we will see how to use Oracle ADF's drag and drop feature by dropping rows from one table to another.

Download the sample code (Jdeveloper PS3)

More info in the video



Have a nice day,
Zeeshan Baig

Monday, January 10, 2011

How to prevent delete on master if child record exists in Oracle ADF

Hi,

In this post we will see how to stop deletion of Master record if child record exists in the database without writing much code.

In this example we have only Departments entity and Employee view object i created a ViewLink between DepartmentsView and EmployeesView and accessing the ViewAccessor in Departments entity.

Later i override the remove() method as follows


  public void remove() {
    RowIterator ri = getEmployeesView();
    int count = ri.getRowCount();
    if (count > 0) {
      throw new JboException("You cannot delete this record, Child record exists!!!");
    } else {
      super.remove();
    }

  }

Download the sample code.

feel free to add more suggestions.

Have a nice day,
Zeeshan Baig