Alloy Showcase
alloy:dataTable
DataTable is a UIData (iterator) component that renders atable
element with tabular data and is designed to be used in conjunction with alloy:column child component tags. Since it extends HtmlDataTable, it supports all the features of h:dataTable.
Sort (Multiple Columns) Usage
In order to enable sorting, the value attribute of the DataTable must implement the Sortable interface (such as OnDemandDataModel). When the user clicks on a sortable column header, the Sortable.setSortCriteria(List<SortCriterion>)
method is called on the DataTable's value. Columns can be made sortable by setting the sortBy attribute of a nested alloy:column
component tag.
Setting multiColumnSort=true
enables the user to hold down the ⌘ or ❖ (meta) key in order to select multiple columns (in a particular order) for sorting.
Source Code
Liferay Faces Alloy 4.1.1 + Liferay Faces Bridge Implementation 5.0.0 + Showcase Common 4.0.0 + Liferay Faces Util 3.4.1 + Mojarra 2.2.20