You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by Ron Smits <ro...@ronsmits.org> on 2007/07/05 17:26:02 UTC

t:columns question

all,

I am implementing an application where tables (t:dataTable) needs to be
built dynamically. Basically all the information comes available from a
service. 

I am building it with the t:columns tag. This tag however will only work
if there is a "real" model with content in the datatable.

the following snippet will not work.
<t:dataTable var="">
<t:columns value="#{table.columns}" var="column">
</tcolumns>
</t:dataTable>

this snippet does work.
<t:dataTable value="#{table.rows}" var="row>
<h:column>
<h:outputText value="#{row}" />
<t:columns value="#{table.columns}" var="column">
</t:columns>
</t:dataTable>

I understand the mechanics at work here, but I was wondering if it was a
deliberate choice. One could argument that a completly built up table
with only <t:columns> would be possible too.

Was this choice deliberate? Or am I inventing a new tag here :)

Ron