Thursday, January 24, 2013

Breadcrumb Navigation in ADF Page

OKAY. So this is based on Region-Country-Location tables of the HR schema. This is the opening page.
User selects 'Americas' from the table displayed above. List of the countries are displayed like below:
Finally user selects 'United States of America' from the table displayed above. This is the final result.

Do notice the breadcrumb navigation as we go deeper into the tables. As there is no dedicated button displayed on the table in order to go to the main table, user can click on 'Main' link displayed on top.

In this sample, we have defined 2 parameters: p_RegionId and p_CountryId.

Now these pageFlowScope variables need to be set when the user clicks on a link in the table. Say like the user selects Americas from the Regions table. So the value #{row.RegionId} needs to be fetched into #{pageFlowScope.RegionId} which is binded with p_RegionId parameter defined in the page. For this we have defined 'Set Action Listener'.
Similarly, for Countries table,
When the user clicks on 'Main' of the breadcrumb navigation,
When the user clicks on Region Name link of the breadcrumb navigation,

This is the method defined in AM. The method is accepting 2 parameters:
1. RegionId: Fetched when the user clicks on any Region
2. CountryId: Fetched when the user clicks on any Country

This method is called on page load. For this, we have to create an executable of type invokeAction, binding the method and then moving to the top position in the executable section.
Also check the Rendered property of the different navigation items and the tables. 

Download the sample application from File Cabinet: RegionCountryLocation.rar


  1. from where we should download the file ? Provide any link