Description
The Table tag renders a complete table including a pager and sortable headers.
Examples
<!-- taglib declaration --> <%@ taglib prefix="tt" uri="/tabletags"%> <!-- A simple example that uses the table tag. --> <tt:table value="items" action="Table" pagerCommand="pagerCommand" pagerValue="pagerDisplay" sortOrder="sortOrder" sortName="sortColumnKey"> <tt:column title="Color" sortKey="col1" sortable="true"> <s:property value="name" /> </tt:column> <tt:column title="Number" sortKey="col2" sortable="true"> <s:property value="value" /> </tt:column> </tt:table>
Table Tag Attributes
Name |
Required |
Type |
Description |
---|---|---|---|
pagerCommand |
false |
String |
the action property name that indicates which page to load |
pagerValue |
false |
PagerDisplay |
the action property that contains the current PagerDisplay |
sortOrder |
false |
String |
the action property name of the sort order |
sortValue |
false |
String |
the currently selected column key |
action |
false |
String |
the name of the action for the links |
namespace |
false |
String |
the namespace of the action for the links |
method |
false |
String |
the action method for the links |
url |
false |
String |
the full url for the link |
Column Tag Attributes
Name |
Required |
Type |
Description |
---|---|---|---|
sortable |
true |
Boolean |
whether or not the user should be allowed to sort the column |
sortKey |
false |
String |
the column key used to determine if the currently selected column |
title |
false |
String |
the title to use for the column header |