Thanks Paul, this seems to be what I need... However, I implemented it now using a trinidad table. The Trinidad table has an attribute varStatus. Is there something simular in the Tobago dataTable?
Joris Paul Spencer-3 wrote: > > Joris, > I am doing something similar using <t:columns>. Their is documentation > on the wiki when this component was in the sandbox [1]. > > Paul Spencer > > [1]http://wiki.apache.org/myfaces/Dynamic_Columns?highlight=(columns) > > Joris Kimpe wrote: >> Hi all, >> >> I have a number of counters that I want to show as nested columns. This >> will look something like this: >> >> | | Counters | >> | Date | AA | BB | CC | DD | EE | >> |-------------|------------------------------ | >> | 22/06/2008 | 0 | 20 | 10 | 0 | 10 | >> | 22/06/2008 | 0 | 21 | 12 | 0 | 12 | >> | 23/06/2008 | 2 | 23 | 15 | 10 | 10 | >> ... >> >> >> In my backing bean I have a List of Objects. For all objects in my list >> I >> want to show a column , but how do I have to dynamically create group >> columns? I already tried this: >> >> <tr:table binding="#{backingBean.overviewTable}" >> value="#{backingBean.dataModel}" var="row"> >> <tr:column headerText="Date"> >> <tr:outputText value="#{row.date}" >> converter="DateConverter"/> >> </tr:column> >> <tr:column headerText="Counters"> >> <c:forEach items="#{row.counters}" var="counter"> >> <tr:column headerText="#{counter.type.id}"> >> <tr:outputText >> value="#{counter.valueString}"/> >> </c:column> >> </tr:forEach> >> </tr:column> >> </tr:table> >> >> The result of the code above, is an empty column under "Counters". Can't >> I >> use c:forEach? Or is there something else wrong? >> >> If I use tr:iterator instead of c:forEach, I get an >> IndexOutOfBoundsException (on position 5). But this is something I don't >> get. This iterator isn't supposed to iterate out of the bounds... Or is >> it? >> >> Using tr:forEach isn't a solution either. This results in an exception >> (noClassDefFoundError javax/servlet/jsp/jstl/core/IndexedValueExpression >> ) >> because it needs the jstl 1.2 library and on this moment I'm only allowed >> to >> use jstl 1.1.2... >> >> Hope someone can help me (or point me to the correct direction) because >> I'm >> searching a couple of days now... Wish there was an easy solution! >> >> Joris > > > -- View this message in context: http://www.nabble.com/-TRINIDAD--Dynamic-column-groups-tp18070579p18085105.html Sent from the MyFaces - Users mailing list archive at Nabble.com.

