2 Replies Latest reply on Dec 16, 2007 5:26 PM by pmuir

    selected tab is lost on sorting of embeded datatable

    marius.oancea

      I have a page with many <rich:tab> components. Each component has it's own dataTable (sortable and paginable). If I select second tab and try to press on sort link, the system reselects the first tab (because page is reloaded).

      One way to prevent this is to do something like this:
      1. add selectedTab attribute
      <rich:tabPanel selectedTab="#{tab}" switchType="ajax" >

      2. add in pages.xml (for this view)

      3. modify all (sort + next / prev) links to send tab parameter.

      4. If you have forms add a hidden field for "tab" to not get lost

      Note: page is backed with entityHome and entityQuery like in seam-gen generated files.

      Is there any better (simpler) solution to do that?