Project Documentation
Foundation

Description

The tag allows dynamic columns in a datatable.

The UIColumns component is used below a t:datatable to create a dynamic count of columns. It is used like a UIData component which iterates through a datamodel to create the columns.

Screen Shot

Not Available

API

component-family javax.faces.Data
renderer-type -
component-class org.apache.myfaces.custom.crosstable.UIColumns
renderer-class -
tag-class org.apache.myfaces.custom.crosstable.HtmlColumnsTag

Usage

<t:dataTable value="#{rows}" var="row">
    <t:columns value="#{cols}" var="column">
        <f:facet name="header">
            <h:outputText value="#{column.name}"/>
        </f:facet>
        <h:outputText value="#{row.columnValue}"/>
    </t:columns>
</t:dataTable>
            

Syntax

<t:columns/>

value - A DataModel, List, Array or a scalar value. Everthing which is accepted for the value attribute of the datatable
var - a variable which can be used to access the current column in the iteration.

witdh - the width of the column.

dir - row cell, ltr | rtl.
lang - row cell, language see RFC 1766
title - row cell, title (tooltip)
style - row cell, inline css-style
styleClass - row cell, css style class
onclick - row cell, onclick event
ondblclick - row cell, ondblclick event
onmousedown - row cell, onmousedown event
onmouseup - row cell, onmouseup event
onmouseover - row cell, onmouseover event
onmousemove - row cell, onmousemove event
onmouseout - row cell, onmouseout event
onkeypress - row cell, onkeypress event
onkeydown - row cell, onkeydown event
onkeyup - row cell, onkeyup event

headerdir - header cell, ltr | rtl.
headerlang - header cell, language see RFC 1766
headertitle - header cell, title (tooltip)
headerstyle - header cell, inline css-style
headerstyleClass - header cell, css style class
headeronclick - header cell, onclick event
headerondblclick - header cell, ondblclick event
headeronmousedown - header cell, onmousedown event
headeronmouseup - header cell, onmouseup event
headeronmouseover - header cell, onmouseover event
headeronmousemove - header cell, onmousemove event
headeronmouseout - header cell, onmouseout event
headeronkeypress - header cell, onkeypress event
headeronkeydown - header cell, onkeydown event
headeronkeyup - header cell, onkeyup event

footerdir - footer cell, ltr | rtl.
footerlang - footer cell, language see RFC 1766
footertitle - footer cell, title (tooltip)
footerstyle - footer cell, inline css-style
footerstyleClass - footer cell, css style class
footeronclick - footer cell, onclick event
footerondblclick - footer cell, ondblclick event
footeronmousedown - footer cell, onmousedown event
footeronmouseup - footer cell, onmouseup event
footeronmouseover - footer cell, onmouseover event
footeronmousemove - footer cell, onmousemove event
footeronmouseout - footer cell, onmouseout event
footeronkeypress - footer cell, onkeypress event
footeronkeydown - footer cell, onkeydown event
footeronkeyup - footer cell, onkeyup event

Instructions

see examples/openDataTable.jsp for an example!