0 Replies Latest reply on Dec 9, 2010 12:28 PM by chuckie474

    rich:dataScroller within a dataTable within a dataTable

    chuckie474

      Hi -

       

      I have a customer requirement to be able to display a table within a column of another table and to also be able to use a data scroller, but for some reason, the data scroller attached to the inner data table doesn't work.  Here is a sample snippet of code:

       

      {code}

      <!-- BEGIN OUTER TABLE -->


      <rich:dataTable id="outerTable" value="#{bean.productList} var="product" rowKeyVar="pRow">


         <rich:column><h:outputText>Rank</h:outputText></rich:column>

         <rich:column><h:commandLink action="#{bean.edit}">Edit</h:commandLink></rich:column>
         <rich:column><h:commandLink action="#{bean.copy}">Copy</h:commandLink></rich:column>

         <rich:column><h:commandLink action="#{bean.delete}">Delete</h:commandLink></rich:column>


         <rich:column>

           <rich:simpleTogglePanel switchType="client">

            <f:facet name="header"><h:outputText value="CLIENT LIST FOR #{product.productName}"/></f:facet>

       

             <!-- BEGIN INNER TABLE -->

              <rich:dataTable id="innerTable" value="#{product.clientList}" var="client"

                rows="20" rowKeyVar="cRow">

                <rich:column><h:outputText value="#{client.clientName}"/></rich:column>

                <rich:column><h:outputText value="#{client.address1}"/></rich:column>

                <rich:column><h:outputText value="#{client.city}"/></rich:column>

                <rich:column><h:outputText value="#{client.state}"/></rich:column>

                <rich:column><h:outputText value="#{client.zip}"/></rich:column>

       

                <f:facet name="footer">

                  <rich:dataScroller id="clientScroller" ajaxSingle="false" renderIfSinglePage="false">

                </f:facet>

              </rich:dataTable>  

             <!-- END INNER TABLE -->

           </rich:simpleTogglePanel>
         </rich:column>

       

      </rich:dataTable>

      <!-- END OUTER TABLE -->

      {code}

       

      Am I missing something? Why does the datascroller not work? I see an ajax request go out through the browser, but it doesn't rerender the inner table.

       

      * If I put a reRender="form:outerTable:#{pRow}:clientTable" I get an console error message saying it can't find component with id: form:outerTable:0:clientTable.

      * If I put a for="form:outerTable:#{pRow}:clientTable" I get a stacktrace saying that it can't find component with id: form:outerTable::clientTable.

       

      Any other ideas?