0 Replies Latest reply on Aug 24, 2009 7:37 PM by jonhsmith

    rich:datatable and sorting (data table)

      I want to have this table with column1 and column2 sorting by richfaces, but the sorting do not appear.

      Can someone help? Thanks.

      column1 | column2 | column3 |
      value1 | value2 | s1 | s2 | s3 |
      value1 | value2 | s1 | s2 | s3 |
      value1 | value2 | s1 | s2 | s3 |
      value1 | value2 | s1 | s2 | s3 |
      value1 | value2 | s1 | s2 | s3 |
      value1 | value2 | s1 | s2 | s3 |

      My code is:

      <rich:dataTable id="table" var="record"
      value="#{tableBean.values}" rows="10" width="100%">
      <f:facet name="header">

      <rich:columnGroup>
      <rich:column>
      <h:outputText value="Column1" />
      </rich:column>

      <rich:column>
      <h:outputText value="Column2" />
      </rich:column>

      <rich:column colspan="3">
      <h:outputText value="Column3" />
      </rich:column>

      </rich:columnGroup>
      </f:facet>

      <rich:column sortBy="record.value1">
      <h:outputText value="record.value1" />
      </rich:column>


      <rich:column>
      <h:outputText value="record.value2" />
      </rich:column>

      <rich:column>
      <h:outputText value="record.s1" />
      </rich:column>

      <rich:column>
      <h:outputText value="record.s2" />
      </rich:column>

      <rich:column>
      <h:outputText value="record.s3" />
      </rich:column>
      </rich:dataTable>

      Can someone help? Thanks