4 Replies Latest reply on Jun 25, 2008 8:58 AM by thinkwise

    tabs reloading everytime

    fstof

      Hi all
      I have an issue where i have a few tabs on a tabpanel it looks like this:

      <rich:tabPanel switchType="ajax" immediate="true" >
       <rich:tab label="My Work" id="myWork">
       <h:form id="myWorkForm">
       <a4j:region id="myWorkRegion">
       <a4j:include viewId="/pages/work/myWorkList.xhtml" />
       </a4j:region>
       </h:form>
       </rich:tab>
      
       <rich:tab label="Customers" id="customer">
       <h:form id="customerForm">
       <a4j:region id="customerRegion">
       <a4j:include viewId="/pages/customer/customerList.xhtml" />
       </a4j:region>
       </h:form>
       </rich:tab>
       ...
      </rich:tabPanel>
      


      now on both the includes (myWorkList.xhtml and customerList.xhtml) have datatables on them like this
      <rich:dataTable id="myWorkListTable" value="#{myWorkListDTO.myWork}" var="workItem">
       <rich:column >
       <f:facet name="header"><h:outputText id="numberHead" value="Work Item Number"/></f:facet>
       <a4j:commandLink value="#{workItem.referenceNumber}" action="..."/>
       </rich:column>
       ...
      </rich:dataTable>
      

      whenever I click on the link of on of the rows on the datatable or on another tab or whatever, all the tabs get reloaded, wich means everytime someone works on the "customer" tab the "my work" tab also gets reloaded unnececary wich is quit expensive.

      How do i get around this?
      Thanks in advance