1 Reply Latest reply on Nov 13, 2008 8:19 AM by ilya_shaikovsky

    Sorting from Rich Data Table header

    erhan14

      I have a rich data table that has a table header. I want to use this header for sorting the columns. Is there a way to sort the table columns from the table header? I do not want to put "header" facet into the table columns definitions. I am defining the column headers in the table header.

      <rich:dataTable id="dataTableTr" value="#{transferQueryController.requestsOfUser}" var="transferReq"
      border="1" cellpadding="2" rows="10">
      <f:facet name="header">
      <rich:columnGroup>
      <rich:column>
      <h:outputText value="#{msg.requestDate}" />
      </rich:column>
      <rich:column>
      <h:outputText value="#{msg.requestUser}" />
      </rich:column>
      </rich:columnGroup>
      </f:facet>
      <rich:columnGroup>
      <rich:column width="50px" id="requestDate">
      <h:outputText value="#{transferReq.requestDate}">
      </h:outputText>
      </rich:column>

      <rich:column width="50px">
      <h:outputText value="#{transferReq.userName}"></h:outputText>
      </rich:column>
      </rich:columnGroup>
      </rich:dataTable>