Uploaded image for project: 'MyFaces Tomahawk'
  1. MyFaces Tomahawk
  2. TOMAHAWK-265

Automatic sort feature for extended data table

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.1.3
    • Component/s: Extended Datatable
    • Labels:
      None
    • Environment:
      All

      Description

      The main new feature is, to allow obtaining a sortable table with little effort. By specifying a sortable=true attribute on the dataTable, command sort header components will be automaticaly added to each column header, if not present already, wrapping the current content of the header facet, and the sorting will be performed by the property obtained from the output component displaying the cell's content. Using the t:column component for the columns, will allow specifying also the default sorted column, using the new defaultSorted=true attribute.

      The actual sorting by columns is handled by a new SortableModel, integrated into MyFaces from ADF Faces, which acts as a wrapper for the current model, and uses row object's properties to perform sort.

      I created also a new page in myfaces examples/simple, to show how can this be used.

      I think it's a nice feature to have, and could be further enhanced, i hope you guys will feel the same.

      Regards,
      Catalin

        Attachments

        1. patch.zip
          15 kB
          Catalin Kormos

          Activity

            People

            • Assignee:
              mmarinschek Martin Marinschek
              Reporter:
              catalean Catalin Kormos
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: