2 Replies Latest reply on Mar 21, 2008 6:33 AM by Alex

    preserver panelMenu expanded group after call

    Alex Newbie

      Hello.

      How do I preserver the expanded group of a panelMenu after a call? My panel Menu has expandSingle="true", and I want the current expanded group to remain expanded after load another page by clicking on a panelMenuItem form the current group.

      The PanelMenu is in a template and all pages have this template.

      Thanks!

        • 1. Re: preserver panelMenu expanded group after call
          Tomislav Tkal?evi? Novice

           

          "powerhouse_b" wrote:
          Hello.

          How do I preserver the expanded group of a panelMenu after a call? My panel Menu has expandSingle="true", and I want the current expanded group to remain expanded after load another page by clicking on a panelMenuItem form the current group.

          The PanelMenu is in a template and all pages have this template.

          Thanks!

          For this component should exist attribute like on rich:tabPanel an that is
          selectedTab...
          Then you could on each enter for each panelGroup call an action which will
          update a currently selected panelGroup (which is a value in some bean),
          then value bind that value to the attribute which should be on the
          panelMenu component...
          Like:

          <rich:panelMenu selectedPanelGroup=#{myBean.selectedPanelGroup}
          


          and every panel
          <rich:panelGroup name="firstPanelGroup" action=#{myBean.setSelectedPanelGroup('firstPanelGroup')}
          




          • 2. Re: preserver panelMenu expanded group after call
            Alex Newbie

            Indeed, it has selectedChild attribute, seems to work. I just thought it would be a simpler solution then binding to a bean.
            Thanks!