Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Database driven menu problem

BilalDec 2 2011 — edited Jan 17 2013
Hi All,

Oracle JDeveloper 11g Release 2.

I am creating application menu from the database in adf page.

The table has the following data:
===================================================
Financials
--Setup
----Financial Calendar
----Financial Books
----Cost Centers
----Chart of Accounts
--Transactions
--Reports
Payroll
--Setup
--Transaction
--Reports
Inventory
Assets
Account Payables
Account Receivables
Control Panel
========================================

I have created an application using the following steps:

1. I created a view object topMenus in the model project.
2. I created a view link to related the menuID and menuBaseID.
3. I added the view object and viewlink in the application module.
4. In the view project, I created a page and then created tree binding for it.
5. I have added the following code to generate the dynamic menu:

=========================================================================
<af:panelAccordion id="acc" discloseMany="false" discloseNone="false">
<af:forEach items="#{bindings.topMenus.children}" var="moduleMenu">
<af:showDetailItem text="#{moduleMenu.MenuLabel}" id="sdi1">
<af:forEach items="#{moduleMenu.children}" var="componentMenu">
<af:showDetailHeader id="sdh1" text="#{componentMenu.MenuLabel}" size="4"
type="stretch">
<af:panelList id="pl1">
<af:forEach items="#{componentMenu.children}" var="taskMenu">
<af:commandLink id="cl1" text="#{taskMenu.MenuLabel}"></af:commandLink>
</af:forEach>
</af:panelList>
</af:showDetailHeader>
</af:forEach>
</af:showDetailItem>
</af:forEach>
</af:panelAccordion>
===========================================================================

5. When I run the form, this is giving the following hierarchy using panelAccordion, detailItem, and commandLink components.

Financials
--Setup
----Financial Calendar
Payroll
--Setup
Inventory
Assets
Account Payables
Account Receivables
Control Panel

===================
A closer look reveals that it is showing only one entry for all the level except level 1.
I dont know how to make this to work fine.

Any help will be highly appreciated.
Thanks ... Best Regards
Bilal

Edited by: Bilal on Dec 2, 2011 9:21 AM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 14 2013
Added on Dec 2 2011
4 comments
151 views