sortableColumn

Purpose

Renders a sortable column to support sorting in tables.

Examples

<g:sortableColumn property="title" title="Title" />
<g:sortableColumn property="title" title="Title" style="width: 200px" />
<g:sortableColumn property="title" titleKey="book.title" />	 
<g:sortableColumn property="releaseDate" defaultOrder="desc" title="Release Date" />
<g:sortableColumn property="releaseDate" defaultOrder="desc" title="Release Date" titleKey="book.releaseDate" />

Description

Attribute title or titleKey is required. When both attributes are specified then titleKey takes precedence, resulting in the title caption to be resolved against the message source. In case when the message could not be resolved, the title will be used as title caption.

Attributes

Source

Show Source