You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Francisco Passos <fr...@gmail.com> on 2007/05/04 13:49:17 UTC

[Trinidad] tr:table within tr:table

Hello there.

I'm attempting to use a tr:table within another one and the second one
doesn't show. I'm trying to present a list of values, where each value may
have a list of different values. So I was aiming for something like

Column 1 | Column 2
---------|-----------
Value 1  | SubValue 1
         | SubValue 2
---------|-----------
Value 2  | SubValue 3
         | SubValue 4
         | SubValue 5

This does not work:

    <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
        <tr:column>
            <tr:outputText value="#{attribute.xnomatrb}"/>
        </tr:column>
        <tr:column rendered="#{attribute.xtipdado eq 'S' or
attribute.xtipdado eq 'L'}">
            <tr:table value="#{attribute.attributeData}"
var="attributeData">
                <tr:column>
                    <tr:outputText value="#{attributeData.xvalor}" />
                </tr:column>
            </tr:table>
        </tr:column>
    </tr:table>


Whereas this does indeed work (the same, but using h:dataTable instead of
tr:table):

    <h:dataTable value="#{fichaOperadorBean.attributes}" var="attribute">
        <h:column>
            <tr:outputText value="#{attribute.xnomatrb}"/>
        </h:column>
        <h:column rendered="#{attribute.xtipdado eq 'S' or
attribute.xtipdado eq 'L'}">
            <h:dataTable value="#{attribute.attributeData}"
var="attributeData">
                <h:column>
                    <tr:outputText value="#{attributeData.xvalor}" />
                </h:column>
            </h:dataTable>
        </h:column>
    </h:dataTable>

Is there another intended way to use tr:table for this to work?

Re: [Trinidad] tr:table within tr:table

Posted by Simon Lessard <si...@gmail.com>.
Hello,

Is there any chance that the facet in error is not that one? Because it
should work.

On 5/7/07, Francisco Passos <fr...@gmail.com> wrote:
>
> After moving "rendered" from f:facet to tr:table, the error remains the
> same, it complains that the facet can only have one child. What could cause
> this?
>
> On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
> >
> > The only obvious problem there is that f:facet doesn't support
> > "rendered" - Facelets should be complaining.  You have to put
> > "rendered" on the table, not the facet.
> >
> > -- Adam
> >
> >
> > On 5/7/07, Francisco Passos < francisco.passos@gmail.com> wrote:
> > > I suppose it should indeed work inside of a column, but it isn't.
> > >
> > > I've tried with a detailStamp like this:
> > >
> > >     <tr:table value="#{ fichaOperadorBean.attributes}" var="attribute"
> > >
> > >         <tr:column>
> > >             <tr:outputText value="#{attribute.xnomatrb}"/>
> > >         </tr:column>
> > >         <f:facet name="detailStamp" rendered="#{attribute.xtipdado eq
> > 'S' or
> > > attribute.xtipdado eq 'L'}">
> > >             <tr:table value="#{attribute.attributeData }"
> > > var="attributeData">
> > >                 <tr:column>
> > >                     <tr:outputText value="#{ attributeData.xvalor}" />
> > >                 </tr:column>
> > >             </tr:table>
> > >         </f:facet>
> > >     </tr:table>
> > >
> > > and I got an error: <f:facet> Facet Tag can only have one child
> > UIComponent
> > >
> > > I don't understand, since the facet only has the tr:table. I also
> > tried it
> > > using a tr:panelGroup with the tr:table in it, but to no avail.
> > >
> > > What can I do?
> > >
> > >
> > > On 5/6/07, Adam Winer <aw...@gmail.com> wrote:
> > > > Hrm.  It is supposed to work inside of a column as well
> > > > as a detailStamp...
> > > >
> > > > -- Adam
> > > >
> > > >
> > > > On 5/4/07, Brian Smith < unobriani@gmail.com> wrote:
> > > > > Try wrapping your nested table inside of a detailStamp facet
> > instead of
> > > a
> > > > > column
> > > > >
> > > > >     <tr:table value="#{ fichaOperadorBean.attributes}"
> > var="attribute">
> > > > >         <tr:column>
> > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > >         </tr:column>
> > > > >         <f:facet name="detailStamp">
> > > > >             <tr:table value="#{attribute.attributeData }"
> > > > > var="attributeData">
> > > > >                 <tr:column>
> > > > >                     <tr:outputText value="#{attributeData.xvalor}"
> > />
> > > > >                 </tr:column>
> > > > >             </tr:table>
> > > > >         </f:facet>
> > > > >     </tr:table>
> > > > >
> > > > > Here is a demo
> > > > >
> > > http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
> > > > >
> > > > > Here is the source
> > > > >
> > > http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
> >
> > > > >
> > > > >
> > > > >  On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
> > > > > > Hello there.
> > > > > >
> > > > > > I'm attempting to use a tr:table within another one and the
> > second one
> > > > > doesn't show. I'm trying to present a list of values, where each
> > value
> > > may
> > > > > have a list of different values. So I was aiming for something
> > like
> > > > > >
> > > > > > Column 1 | Column 2
> > > > > > ---------|-----------
> > > > > > Value 1  | SubValue 1
> > > > > >          | SubValue 2
> > > > > > ---------|-----------
> > > > > > Value 2  | SubValue 3
> > > > > >          | SubValue 4
> > > > > >          | SubValue 5
> > > > > >
> > > > > > This does not work:
> > > > > >
> > > > > >     <tr:table value="#{fichaOperadorBean.attributes}"
> > var="attribute">
> > > > > >         <tr:column>
> > > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > > >         </tr:column>
> > > > > >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > attribute.xtipdado eq 'L'}">
> > > > > >             <tr:table value="#{ attribute.attributeData }"
> > > > > var="attributeData">
> > > > > >                 <tr:column>
> > > > > >                     <tr:outputText value="#{
> > attributeData.xvalor}" />
> > > > > >                 </tr:column>
> > > > > >             </tr:table>
> > > > > >         </tr:column>
> > > > > >     </tr:table>
> > > > > >
> > > > > >
> > > > > > Whereas this does indeed work (the same, but using h:dataTable
> > instead
> > > of
> > > > > tr:table):
> > > > > >
> > > > > >     <h:dataTable value="#{ fichaOperadorBean.attributes }"
> > > var="attribute">
> > > > > >         <h:column>
> > > > > >             <tr:outputText value="#{ attribute.xnomatrb}"/>
> > > > > >         </h:column>
> > > > > >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > attribute.xtipdado eq 'L'}">
> > > > > >             <h:dataTable value="#{ attribute.attributeData}"
> > > > > var="attributeData">
> > > > > >                 <h:column>
> > > > > >                     <tr:outputText value="#{
> > attributeData.xvalor }" />
> > > > > >                 </h:column>
> > > > > >             </h:dataTable>
> > > > > >         </h:column>
> > > > > >     </h:dataTable>
> > > > > >
> > > > > > Is there another intended way to use tr:table for this to work?
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > >
> > >
> >
>
>

Re: [Trinidad] tr:table within tr:table

Posted by Francisco Passos <fr...@gmail.com>.
This was it! :)

When I said it didn't work, I meant that the inner table did not render.
However, after moving the rendered attribute from the <tr:column> to the
inner <tr:table>, it works fine.

Thanks for helping me with this problem.

Francisco Passos

On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
>
> Also, when you said that table-in-table "doesn't work",
> what do you mean?  What exactly isn't working?
>
> I suspect that your original problem was that the
> Trinidad table does not support "rendered" being bound
> per-row on a column.  Columns are either entirely
> rendered or entirely hidden.
>
>     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
>         <tr:column>
>             <tr:outputText value="#{attribute.xnomatrb }"/>
>         </tr:column>
>         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> attribute.xtipdado eq 'L'}">
>             <tr:table value="#{attribute.attributeData }"
> var="attributeData">
>                 <tr:column>
>                     <tr:outputText value="#{attributeData.xvalor}" />
>                 </tr:column>
>             </tr:table>
>         </tr:column>
>     </tr:table>
>
> Move the "rendered" here off of column and down to the table.
> It's evaluating once, without any "attribute", at which point
> the expression is "null eq S or null eq L", which is false,
> so the column doesn't render at all.
>
>
> -- Adam
>
>
> On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
> > Don't know.  I'd ask on the facelets list.  Do you happen
> > to have any comments inside the facet, or have you
> > e-mailed the exact XML content you're using?
> >
> > -- Adam
> >
> >
> > On 5/7/07, Francisco Passos <fr...@gmail.com> wrote:
> > > After moving "rendered" from f:facet to tr:table, the error remains
> the
> > > same, it complains that the facet can only have one child. What could
> cause
> > > this?
> > >
> > >
> > > On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
> > > > The only obvious problem there is that f:facet doesn't support
> > > > "rendered" - Facelets should be complaining.  You have to put
> > > > "rendered" on the table, not the facet.
> > > >
> > > > -- Adam
> > > >
> > > >
> > > > On 5/7/07, Francisco Passos < francisco.passos@gmail.com> wrote:
> > > > > I suppose it should indeed work inside of a column, but it isn't.
> > > > >
> > > > > I've tried with a detailStamp like this:
> > > > >
> > > > >     <tr:table value="#{ fichaOperadorBean.attributes}"
> var="attribute" >
> > > > >         <tr:column>
> > > > >             <tr:outputText value="#{attribute.xnomatrb}"/>
> > > > >         </tr:column>
> > > > >         <f:facet name="detailStamp" rendered="#{attribute.xtipdadoeq
> > > 'S' or
> > > > > attribute.xtipdado eq 'L'}">
> > > > >             <tr:table value="#{attribute.attributeData }"
> > > > > var="attributeData">
> > > > >                 <tr:column>
> > > > >                     <tr:outputText value="#{ attributeData.xvalor}"
> />
> > > > >                 </tr:column>
> > > > >             </tr:table>
> > > > >         </f:facet>
> > > > >     </tr:table>
> > > > >
> > > > > and I got an error: <f:facet> Facet Tag can only have one child
> > > UIComponent
> > > > >
> > > > > I don't understand, since the facet only has the tr:table. I also
> tried
> > > it
> > > > > using a tr:panelGroup with the tr:table in it, but to no avail.
> > > > >
> > > > > What can I do?
> > > > >
> > > > >
> > > > > On 5/6/07, Adam Winer <aw...@gmail.com> wrote:
> > > > > > Hrm.  It is supposed to work inside of a column as well
> > > > > > as a detailStamp...
> > > > > >
> > > > > > -- Adam
> > > > > >
> > > > > >
> > > > > > On 5/4/07, Brian Smith < unobriani@gmail.com> wrote:
> > > > > > > Try wrapping your nested table inside of a detailStamp facet
> instead
> > > of
> > > > > a
> > > > > > > column
> > > > > > >
> > > > > > >     <tr:table value="#{ fichaOperadorBean.attributes}"
> > > var="attribute">
> > > > > > >         <tr:column>
> > > > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > > > >         </tr:column>
> > > > > > >         <f:facet name="detailStamp">
> > > > > > >             <tr:table value="#{attribute.attributeData }"
> > > > > > > var="attributeData">
> > > > > > >                 <tr:column>
> > > > > > >                     <tr:outputText value="#{
> attributeData.xvalor}"
> > > />
> > > > > > >                 </tr:column>
> > > > > > >             </tr:table>
> > > > > > >         </f:facet>
> > > > > > >     </tr:table>
> > > > > > >
> > > > > > > Here is a demo
> > > > > > >
> > > > >
> > > http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
> > > > > > >
> > > > > > > Here is the source
> > > > > > >
> > > > >
> > >
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
> > > > > > >
> > > > > > >
> > > > > > >  On 5/4/07, Francisco Passos <fr...@gmail.com>
> wrote:
> > > > > > > > Hello there.
> > > > > > > >
> > > > > > > > I'm attempting to use a tr:table within another one and the
> second
> > > one
> > > > > > > doesn't show. I'm trying to present a list of values, where
> each
> > > value
> > > > > may
> > > > > > > have a list of different values. So I was aiming for something
> like
> > > > > > > >
> > > > > > > > Column 1 | Column 2
> > > > > > > > ---------|-----------
> > > > > > > > Value 1  | SubValue 1
> > > > > > > >          | SubValue 2
> > > > > > > > ---------|-----------
> > > > > > > > Value 2  | SubValue 3
> > > > > > > >          | SubValue 4
> > > > > > > >          | SubValue 5
> > > > > > > >
> > > > > > > > This does not work:
> > > > > > > >
> > > > > > > >     <tr:table value="#{fichaOperadorBean.attributes}"
> > > var="attribute">
> > > > > > > >         <tr:column>
> > > > > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > > > > >         </tr:column>
> > > > > > > >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > > > attribute.xtipdado eq 'L'}">
> > > > > > > >             <tr:table value="#{ attribute.attributeData }"
> > > > > > > var="attributeData">
> > > > > > > >                 <tr:column>
> > > > > > > >                     <tr:outputText value="#{
> > > attributeData.xvalor}" />
> > > > > > > >                 </tr:column>
> > > > > > > >             </tr:table>
> > > > > > > >         </tr:column>
> > > > > > > >     </tr:table>
> > > > > > > >
> > > > > > > >
> > > > > > > > Whereas this does indeed work (the same, but using
> h:dataTable
> > > instead
> > > > > of
> > > > > > > tr:table):
> > > > > > > >
> > > > > > > >     <h:dataTable value="#{ fichaOperadorBean.attributes }"
> > > > > var="attribute">
> > > > > > > >         <h:column>
> > > > > > > >             <tr:outputText value="#{ attribute.xnomatrb}"/>
> > > > > > > >         </h:column>
> > > > > > > >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > > > attribute.xtipdado eq 'L'}">
> > > > > > > >             <h:dataTable value="#{ attribute.attributeData}"
> > > > > > > var="attributeData">
> > > > > > > >                 <h:column>
> > > > > > > >                     <tr:outputText value="#{
> attributeData.xvalor
> > > }" />
> > > > > > > >                 </h:column>
> > > > > > > >             </h:dataTable>
> > > > > > > >         </h:column>
> > > > > > > >     </h:dataTable>
> > > > > > > >
> > > > > > > > Is there another intended way to use tr:table for this to
> work?
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > >
> > >
> >
>

Re: [Trinidad] tr:table within tr:table

Posted by Adam Winer <aw...@gmail.com>.
Also, when you said that table-in-table "doesn't work",
what do you mean?  What exactly isn't working?

I suspect that your original problem was that the
Trinidad table does not support "rendered" being bound
per-row on a column.  Columns are either entirely
rendered or entirely hidden.

    <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
        <tr:column>
            <tr:outputText value="#{attribute.xnomatrb }"/>
        </tr:column>
        <tr:column rendered="#{attribute.xtipdado eq 'S' or
attribute.xtipdado eq 'L'}">
            <tr:table value="#{attribute.attributeData }" var="attributeData">
                <tr:column>
                    <tr:outputText value="#{attributeData.xvalor}" />
                </tr:column>
            </tr:table>
        </tr:column>
    </tr:table>

Move the "rendered" here off of column and down to the table.
It's evaluating once, without any "attribute", at which point
the expression is "null eq S or null eq L", which is false,
so the column doesn't render at all.


-- Adam


On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
> Don't know.  I'd ask on the facelets list.  Do you happen
> to have any comments inside the facet, or have you
> e-mailed the exact XML content you're using?
>
> -- Adam
>
>
> On 5/7/07, Francisco Passos <fr...@gmail.com> wrote:
> > After moving "rendered" from f:facet to tr:table, the error remains the
> > same, it complains that the facet can only have one child. What could cause
> > this?
> >
> >
> > On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
> > > The only obvious problem there is that f:facet doesn't support
> > > "rendered" - Facelets should be complaining.  You have to put
> > > "rendered" on the table, not the facet.
> > >
> > > -- Adam
> > >
> > >
> > > On 5/7/07, Francisco Passos < francisco.passos@gmail.com> wrote:
> > > > I suppose it should indeed work inside of a column, but it isn't.
> > > >
> > > > I've tried with a detailStamp like this:
> > > >
> > > >     <tr:table value="#{ fichaOperadorBean.attributes}" var="attribute" >
> > > >         <tr:column>
> > > >             <tr:outputText value="#{attribute.xnomatrb}"/>
> > > >         </tr:column>
> > > >         <f:facet name="detailStamp" rendered="#{attribute.xtipdado eq
> > 'S' or
> > > > attribute.xtipdado eq 'L'}">
> > > >             <tr:table value="#{attribute.attributeData }"
> > > > var="attributeData">
> > > >                 <tr:column>
> > > >                     <tr:outputText value="#{ attributeData.xvalor}" />
> > > >                 </tr:column>
> > > >             </tr:table>
> > > >         </f:facet>
> > > >     </tr:table>
> > > >
> > > > and I got an error: <f:facet> Facet Tag can only have one child
> > UIComponent
> > > >
> > > > I don't understand, since the facet only has the tr:table. I also tried
> > it
> > > > using a tr:panelGroup with the tr:table in it, but to no avail.
> > > >
> > > > What can I do?
> > > >
> > > >
> > > > On 5/6/07, Adam Winer <aw...@gmail.com> wrote:
> > > > > Hrm.  It is supposed to work inside of a column as well
> > > > > as a detailStamp...
> > > > >
> > > > > -- Adam
> > > > >
> > > > >
> > > > > On 5/4/07, Brian Smith < unobriani@gmail.com> wrote:
> > > > > > Try wrapping your nested table inside of a detailStamp facet instead
> > of
> > > > a
> > > > > > column
> > > > > >
> > > > > >     <tr:table value="#{ fichaOperadorBean.attributes}"
> > var="attribute">
> > > > > >         <tr:column>
> > > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > > >         </tr:column>
> > > > > >         <f:facet name="detailStamp">
> > > > > >             <tr:table value="#{attribute.attributeData }"
> > > > > > var="attributeData">
> > > > > >                 <tr:column>
> > > > > >                     <tr:outputText value="#{attributeData.xvalor}"
> > />
> > > > > >                 </tr:column>
> > > > > >             </tr:table>
> > > > > >         </f:facet>
> > > > > >     </tr:table>
> > > > > >
> > > > > > Here is a demo
> > > > > >
> > > >
> > http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
> > > > > >
> > > > > > Here is the source
> > > > > >
> > > >
> > http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
> > > > > >
> > > > > >
> > > > > >  On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
> > > > > > > Hello there.
> > > > > > >
> > > > > > > I'm attempting to use a tr:table within another one and the second
> > one
> > > > > > doesn't show. I'm trying to present a list of values, where each
> > value
> > > > may
> > > > > > have a list of different values. So I was aiming for something like
> > > > > > >
> > > > > > > Column 1 | Column 2
> > > > > > > ---------|-----------
> > > > > > > Value 1  | SubValue 1
> > > > > > >          | SubValue 2
> > > > > > > ---------|-----------
> > > > > > > Value 2  | SubValue 3
> > > > > > >          | SubValue 4
> > > > > > >          | SubValue 5
> > > > > > >
> > > > > > > This does not work:
> > > > > > >
> > > > > > >     <tr:table value="#{fichaOperadorBean.attributes}"
> > var="attribute">
> > > > > > >         <tr:column>
> > > > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > > > >         </tr:column>
> > > > > > >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > > attribute.xtipdado eq 'L'}">
> > > > > > >             <tr:table value="#{ attribute.attributeData }"
> > > > > > var="attributeData">
> > > > > > >                 <tr:column>
> > > > > > >                     <tr:outputText value="#{
> > attributeData.xvalor}" />
> > > > > > >                 </tr:column>
> > > > > > >             </tr:table>
> > > > > > >         </tr:column>
> > > > > > >     </tr:table>
> > > > > > >
> > > > > > >
> > > > > > > Whereas this does indeed work (the same, but using h:dataTable
> > instead
> > > > of
> > > > > > tr:table):
> > > > > > >
> > > > > > >     <h:dataTable value="#{ fichaOperadorBean.attributes }"
> > > > var="attribute">
> > > > > > >         <h:column>
> > > > > > >             <tr:outputText value="#{ attribute.xnomatrb}"/>
> > > > > > >         </h:column>
> > > > > > >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > > attribute.xtipdado eq 'L'}">
> > > > > > >             <h:dataTable value="#{ attribute.attributeData}"
> > > > > > var="attributeData">
> > > > > > >                 <h:column>
> > > > > > >                     <tr:outputText value="#{ attributeData.xvalor
> > }" />
> > > > > > >                 </h:column>
> > > > > > >             </h:dataTable>
> > > > > > >         </h:column>
> > > > > > >     </h:dataTable>
> > > > > > >
> > > > > > > Is there another intended way to use tr:table for this to work?
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > >
> >
> >
>

Re: [Trinidad] tr:table within tr:table

Posted by Adam Winer <aw...@gmail.com>.
Don't know.  I'd ask on the facelets list.  Do you happen
to have any comments inside the facet, or have you
e-mailed the exact XML content you're using?

-- Adam


On 5/7/07, Francisco Passos <fr...@gmail.com> wrote:
> After moving "rendered" from f:facet to tr:table, the error remains the
> same, it complains that the facet can only have one child. What could cause
> this?
>
>
> On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
> > The only obvious problem there is that f:facet doesn't support
> > "rendered" - Facelets should be complaining.  You have to put
> > "rendered" on the table, not the facet.
> >
> > -- Adam
> >
> >
> > On 5/7/07, Francisco Passos < francisco.passos@gmail.com> wrote:
> > > I suppose it should indeed work inside of a column, but it isn't.
> > >
> > > I've tried with a detailStamp like this:
> > >
> > >     <tr:table value="#{ fichaOperadorBean.attributes}" var="attribute" >
> > >         <tr:column>
> > >             <tr:outputText value="#{attribute.xnomatrb}"/>
> > >         </tr:column>
> > >         <f:facet name="detailStamp" rendered="#{attribute.xtipdado eq
> 'S' or
> > > attribute.xtipdado eq 'L'}">
> > >             <tr:table value="#{attribute.attributeData }"
> > > var="attributeData">
> > >                 <tr:column>
> > >                     <tr:outputText value="#{ attributeData.xvalor}" />
> > >                 </tr:column>
> > >             </tr:table>
> > >         </f:facet>
> > >     </tr:table>
> > >
> > > and I got an error: <f:facet> Facet Tag can only have one child
> UIComponent
> > >
> > > I don't understand, since the facet only has the tr:table. I also tried
> it
> > > using a tr:panelGroup with the tr:table in it, but to no avail.
> > >
> > > What can I do?
> > >
> > >
> > > On 5/6/07, Adam Winer <aw...@gmail.com> wrote:
> > > > Hrm.  It is supposed to work inside of a column as well
> > > > as a detailStamp...
> > > >
> > > > -- Adam
> > > >
> > > >
> > > > On 5/4/07, Brian Smith < unobriani@gmail.com> wrote:
> > > > > Try wrapping your nested table inside of a detailStamp facet instead
> of
> > > a
> > > > > column
> > > > >
> > > > >     <tr:table value="#{ fichaOperadorBean.attributes}"
> var="attribute">
> > > > >         <tr:column>
> > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > >         </tr:column>
> > > > >         <f:facet name="detailStamp">
> > > > >             <tr:table value="#{attribute.attributeData }"
> > > > > var="attributeData">
> > > > >                 <tr:column>
> > > > >                     <tr:outputText value="#{attributeData.xvalor}"
> />
> > > > >                 </tr:column>
> > > > >             </tr:table>
> > > > >         </f:facet>
> > > > >     </tr:table>
> > > > >
> > > > > Here is a demo
> > > > >
> > >
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
> > > > >
> > > > > Here is the source
> > > > >
> > >
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
> > > > >
> > > > >
> > > > >  On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
> > > > > > Hello there.
> > > > > >
> > > > > > I'm attempting to use a tr:table within another one and the second
> one
> > > > > doesn't show. I'm trying to present a list of values, where each
> value
> > > may
> > > > > have a list of different values. So I was aiming for something like
> > > > > >
> > > > > > Column 1 | Column 2
> > > > > > ---------|-----------
> > > > > > Value 1  | SubValue 1
> > > > > >          | SubValue 2
> > > > > > ---------|-----------
> > > > > > Value 2  | SubValue 3
> > > > > >          | SubValue 4
> > > > > >          | SubValue 5
> > > > > >
> > > > > > This does not work:
> > > > > >
> > > > > >     <tr:table value="#{fichaOperadorBean.attributes}"
> var="attribute">
> > > > > >         <tr:column>
> > > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > > >         </tr:column>
> > > > > >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > attribute.xtipdado eq 'L'}">
> > > > > >             <tr:table value="#{ attribute.attributeData }"
> > > > > var="attributeData">
> > > > > >                 <tr:column>
> > > > > >                     <tr:outputText value="#{
> attributeData.xvalor}" />
> > > > > >                 </tr:column>
> > > > > >             </tr:table>
> > > > > >         </tr:column>
> > > > > >     </tr:table>
> > > > > >
> > > > > >
> > > > > > Whereas this does indeed work (the same, but using h:dataTable
> instead
> > > of
> > > > > tr:table):
> > > > > >
> > > > > >     <h:dataTable value="#{ fichaOperadorBean.attributes }"
> > > var="attribute">
> > > > > >         <h:column>
> > > > > >             <tr:outputText value="#{ attribute.xnomatrb}"/>
> > > > > >         </h:column>
> > > > > >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> > > > > attribute.xtipdado eq 'L'}">
> > > > > >             <h:dataTable value="#{ attribute.attributeData}"
> > > > > var="attributeData">
> > > > > >                 <h:column>
> > > > > >                     <tr:outputText value="#{ attributeData.xvalor
> }" />
> > > > > >                 </h:column>
> > > > > >             </h:dataTable>
> > > > > >         </h:column>
> > > > > >     </h:dataTable>
> > > > > >
> > > > > > Is there another intended way to use tr:table for this to work?
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > >
> > >
> >
>
>

Re: [Trinidad] tr:table within tr:table

Posted by Francisco Passos <fr...@gmail.com>.
After moving "rendered" from f:facet to tr:table, the error remains the
same, it complains that the facet can only have one child. What could cause
this?

On 5/7/07, Adam Winer <aw...@gmail.com> wrote:
>
> The only obvious problem there is that f:facet doesn't support
> "rendered" - Facelets should be complaining.  You have to put
> "rendered" on the table, not the facet.
>
> -- Adam
>
>
> On 5/7/07, Francisco Passos <fr...@gmail.com> wrote:
> > I suppose it should indeed work inside of a column, but it isn't.
> >
> > I've tried with a detailStamp like this:
> >
> >     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute" >
> >         <tr:column>
> >             <tr:outputText value="#{attribute.xnomatrb}"/>
> >         </tr:column>
> >         <f:facet name="detailStamp" rendered="#{attribute.xtipdado eq
> 'S' or
> > attribute.xtipdado eq 'L'}">
> >             <tr:table value="#{attribute.attributeData}"
> > var="attributeData">
> >                 <tr:column>
> >                     <tr:outputText value="#{ attributeData.xvalor}" />
> >                 </tr:column>
> >             </tr:table>
> >         </f:facet>
> >     </tr:table>
> >
> > and I got an error: <f:facet> Facet Tag can only have one child
> UIComponent
> >
> > I don't understand, since the facet only has the tr:table. I also tried
> it
> > using a tr:panelGroup with the tr:table in it, but to no avail.
> >
> > What can I do?
> >
> >
> > On 5/6/07, Adam Winer <aw...@gmail.com> wrote:
> > > Hrm.  It is supposed to work inside of a column as well
> > > as a detailStamp...
> > >
> > > -- Adam
> > >
> > >
> > > On 5/4/07, Brian Smith <un...@gmail.com> wrote:
> > > > Try wrapping your nested table inside of a detailStamp facet instead
> of
> > a
> > > > column
> > > >
> > > >     <tr:table value="#{fichaOperadorBean.attributes}"
> var="attribute">
> > > >         <tr:column>
> > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > >         </tr:column>
> > > >         <f:facet name="detailStamp">
> > > >             <tr:table value="#{attribute.attributeData }"
> > > > var="attributeData">
> > > >                 <tr:column>
> > > >                     <tr:outputText value="#{attributeData.xvalor}"
> />
> > > >                 </tr:column>
> > > >             </tr:table>
> > > >         </f:facet>
> > > >     </tr:table>
> > > >
> > > > Here is a demo
> > > >
> > http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
> > > >
> > > > Here is the source
> > > >
> >
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
> > > >
> > > >
> > > >  On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
> > > > > Hello there.
> > > > >
> > > > > I'm attempting to use a tr:table within another one and the second
> one
> > > > doesn't show. I'm trying to present a list of values, where each
> value
> > may
> > > > have a list of different values. So I was aiming for something like
> > > > >
> > > > > Column 1 | Column 2
> > > > > ---------|-----------
> > > > > Value 1  | SubValue 1
> > > > >          | SubValue 2
> > > > > ---------|-----------
> > > > > Value 2  | SubValue 3
> > > > >          | SubValue 4
> > > > >          | SubValue 5
> > > > >
> > > > > This does not work:
> > > > >
> > > > >     <tr:table value="#{fichaOperadorBean.attributes}"
> var="attribute">
> > > > >         <tr:column>
> > > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > > >         </tr:column>
> > > > >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> > > > attribute.xtipdado eq 'L'}">
> > > > >             <tr:table value="#{ attribute.attributeData }"
> > > > var="attributeData">
> > > > >                 <tr:column>
> > > > >                     <tr:outputText value="#{attributeData.xvalor}"
> />
> > > > >                 </tr:column>
> > > > >             </tr:table>
> > > > >         </tr:column>
> > > > >     </tr:table>
> > > > >
> > > > >
> > > > > Whereas this does indeed work (the same, but using h:dataTable
> instead
> > of
> > > > tr:table):
> > > > >
> > > > >     <h:dataTable value="#{fichaOperadorBean.attributes }"
> > var="attribute">
> > > > >         <h:column>
> > > > >             <tr:outputText value="#{ attribute.xnomatrb}"/>
> > > > >         </h:column>
> > > > >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> > > > attribute.xtipdado eq 'L'}">
> > > > >             <h:dataTable value="#{ attribute.attributeData}"
> > > > var="attributeData">
> > > > >                 <h:column>
> > > > >                     <tr:outputText value="#{ attributeData.xvalor}"
> />
> > > > >                 </h:column>
> > > > >             </h:dataTable>
> > > > >         </h:column>
> > > > >     </h:dataTable>
> > > > >
> > > > > Is there another intended way to use tr:table for this to work?
> > > > >
> > > > >
> > > >
> > > >
> > >
> >
> >
>

Re: [Trinidad] tr:table within tr:table

Posted by Adam Winer <aw...@gmail.com>.
The only obvious problem there is that f:facet doesn't support
"rendered" - Facelets should be complaining.  You have to put
"rendered" on the table, not the facet.

-- Adam


On 5/7/07, Francisco Passos <fr...@gmail.com> wrote:
> I suppose it should indeed work inside of a column, but it isn't.
>
> I've tried with a detailStamp like this:
>
>     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute" >
>         <tr:column>
>             <tr:outputText value="#{attribute.xnomatrb}"/>
>         </tr:column>
>         <f:facet name="detailStamp" rendered="#{attribute.xtipdado eq 'S' or
> attribute.xtipdado eq 'L'}">
>             <tr:table value="#{attribute.attributeData}"
> var="attributeData">
>                 <tr:column>
>                     <tr:outputText value="#{ attributeData.xvalor}" />
>                 </tr:column>
>             </tr:table>
>         </f:facet>
>     </tr:table>
>
> and I got an error: <f:facet> Facet Tag can only have one child UIComponent
>
> I don't understand, since the facet only has the tr:table. I also tried it
> using a tr:panelGroup with the tr:table in it, but to no avail.
>
> What can I do?
>
>
> On 5/6/07, Adam Winer <aw...@gmail.com> wrote:
> > Hrm.  It is supposed to work inside of a column as well
> > as a detailStamp...
> >
> > -- Adam
> >
> >
> > On 5/4/07, Brian Smith <un...@gmail.com> wrote:
> > > Try wrapping your nested table inside of a detailStamp facet instead of
> a
> > > column
> > >
> > >     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
> > >         <tr:column>
> > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > >         </tr:column>
> > >         <f:facet name="detailStamp">
> > >             <tr:table value="#{attribute.attributeData }"
> > > var="attributeData">
> > >                 <tr:column>
> > >                     <tr:outputText value="#{attributeData.xvalor}" />
> > >                 </tr:column>
> > >             </tr:table>
> > >         </f:facet>
> > >     </tr:table>
> > >
> > > Here is a demo
> > >
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
> > >
> > > Here is the source
> > >
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
> > >
> > >
> > >  On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
> > > > Hello there.
> > > >
> > > > I'm attempting to use a tr:table within another one and the second one
> > > doesn't show. I'm trying to present a list of values, where each value
> may
> > > have a list of different values. So I was aiming for something like
> > > >
> > > > Column 1 | Column 2
> > > > ---------|-----------
> > > > Value 1  | SubValue 1
> > > >          | SubValue 2
> > > > ---------|-----------
> > > > Value 2  | SubValue 3
> > > >          | SubValue 4
> > > >          | SubValue 5
> > > >
> > > > This does not work:
> > > >
> > > >     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
> > > >         <tr:column>
> > > >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> > > >         </tr:column>
> > > >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> > > attribute.xtipdado eq 'L'}">
> > > >             <tr:table value="#{ attribute.attributeData }"
> > > var="attributeData">
> > > >                 <tr:column>
> > > >                     <tr:outputText value="#{attributeData.xvalor}" />
> > > >                 </tr:column>
> > > >             </tr:table>
> > > >         </tr:column>
> > > >     </tr:table>
> > > >
> > > >
> > > > Whereas this does indeed work (the same, but using h:dataTable instead
> of
> > > tr:table):
> > > >
> > > >     <h:dataTable value="#{fichaOperadorBean.attributes }"
> var="attribute">
> > > >         <h:column>
> > > >             <tr:outputText value="#{ attribute.xnomatrb}"/>
> > > >         </h:column>
> > > >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> > > attribute.xtipdado eq 'L'}">
> > > >             <h:dataTable value="#{ attribute.attributeData}"
> > > var="attributeData">
> > > >                 <h:column>
> > > >                     <tr:outputText value="#{ attributeData.xvalor}" />
> > > >                 </h:column>
> > > >             </h:dataTable>
> > > >         </h:column>
> > > >     </h:dataTable>
> > > >
> > > > Is there another intended way to use tr:table for this to work?
> > > >
> > > >
> > >
> > >
> >
>
>

Re: [Trinidad] tr:table within tr:table

Posted by Francisco Passos <fr...@gmail.com>.
I suppose it should indeed work inside of a column, but it isn't.

I've tried with a detailStamp like this:

    <tr:table value="#{fichaOperadorBean.attributes}" var="attribute" >
        <tr:column>
            <tr:outputText value="#{attribute.xnomatrb}"/>
        </tr:column>
        <f:facet name="detailStamp" rendered="#{attribute.xtipdado eq 'S' or
attribute.xtipdado eq 'L'}">
            <tr:table value="#{attribute.attributeData}"
var="attributeData">
                <tr:column>
                    <tr:outputText value="#{attributeData.xvalor}" />
                </tr:column>
            </tr:table>
        </f:facet>
    </tr:table>

and I got an error: <f:facet> Facet Tag can only have one child UIComponent

I don't understand, since the facet only has the tr:table. I also tried it
using a tr:panelGroup with the tr:table in it, but to no avail.

What can I do?

On 5/6/07, Adam Winer <aw...@gmail.com> wrote:
>
> Hrm.  It is supposed to work inside of a column as well
> as a detailStamp...
>
> -- Adam
>
>
> On 5/4/07, Brian Smith <un...@gmail.com> wrote:
> > Try wrapping your nested table inside of a detailStamp facet instead of
> a
> > column
> >
> >     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
> >         <tr:column>
> >             <tr:outputText value="#{ attribute.xnomatrb }"/>
> >         </tr:column>
> >         <f:facet name="detailStamp">
> >             <tr:table value="#{attribute.attributeData }"
> > var="attributeData">
> >                 <tr:column>
> >                     <tr:outputText value="#{attributeData.xvalor}" />
> >                 </tr:column>
> >             </tr:table>
> >         </f:facet>
> >     </tr:table>
> >
> > Here is a demo
> > http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
> >
> > Here is the source
> >
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
> >
> >
> >  On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
> > > Hello there.
> > >
> > > I'm attempting to use a tr:table within another one and the second one
> > doesn't show. I'm trying to present a list of values, where each value
> may
> > have a list of different values. So I was aiming for something like
> > >
> > > Column 1 | Column 2
> > > ---------|-----------
> > > Value 1  | SubValue 1
> > >          | SubValue 2
> > > ---------|-----------
> > > Value 2  | SubValue 3
> > >          | SubValue 4
> > >          | SubValue 5
> > >
> > > This does not work:
> > >
> > >     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
> > >         <tr:column>
> > >             <tr:outputText value="#{attribute.xnomatrb }"/>
> > >         </tr:column>
> > >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> > attribute.xtipdado eq 'L'}">
> > >             <tr:table value="#{attribute.attributeData }"
> > var="attributeData">
> > >                 <tr:column>
> > >                     <tr:outputText value="#{attributeData.xvalor}" />
> > >                 </tr:column>
> > >             </tr:table>
> > >         </tr:column>
> > >     </tr:table>
> > >
> > >
> > > Whereas this does indeed work (the same, but using h:dataTable instead
> of
> > tr:table):
> > >
> > >     <h:dataTable value="#{fichaOperadorBean.attributes }"
> var="attribute">
> > >         <h:column>
> > >             <tr:outputText value="#{attribute.xnomatrb}"/>
> > >         </h:column>
> > >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> > attribute.xtipdado eq 'L'}">
> > >             <h:dataTable value="#{attribute.attributeData}"
> > var="attributeData">
> > >                 <h:column>
> > >                     <tr:outputText value="#{ attributeData.xvalor}" />
> > >                 </h:column>
> > >             </h:dataTable>
> > >         </h:column>
> > >     </h:dataTable>
> > >
> > > Is there another intended way to use tr:table for this to work?
> > >
> > >
> >
> >
>

Re: [Trinidad] tr:table within tr:table

Posted by Adam Winer <aw...@gmail.com>.
Hrm.  It is supposed to work inside of a column as well
as a detailStamp...

-- Adam


On 5/4/07, Brian Smith <un...@gmail.com> wrote:
> Try wrapping your nested table inside of a detailStamp facet instead of a
> column
>
>     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
>         <tr:column>
>             <tr:outputText value="#{ attribute.xnomatrb }"/>
>         </tr:column>
>         <f:facet name="detailStamp">
>             <tr:table value="#{attribute.attributeData }"
> var="attributeData">
>                 <tr:column>
>                     <tr:outputText value="#{attributeData.xvalor}" />
>                 </tr:column>
>             </tr:table>
>         </f:facet>
>     </tr:table>
>
> Here is a demo
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx
>
> Here is the source
> http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source
>
>
>  On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
> > Hello there.
> >
> > I'm attempting to use a tr:table within another one and the second one
> doesn't show. I'm trying to present a list of values, where each value may
> have a list of different values. So I was aiming for something like
> >
> > Column 1 | Column 2
> > ---------|-----------
> > Value 1  | SubValue 1
> >          | SubValue 2
> > ---------|-----------
> > Value 2  | SubValue 3
> >          | SubValue 4
> >          | SubValue 5
> >
> > This does not work:
> >
> >     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
> >         <tr:column>
> >             <tr:outputText value="#{attribute.xnomatrb }"/>
> >         </tr:column>
> >         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> attribute.xtipdado eq 'L'}">
> >             <tr:table value="#{attribute.attributeData }"
> var="attributeData">
> >                 <tr:column>
> >                     <tr:outputText value="#{attributeData.xvalor}" />
> >                 </tr:column>
> >             </tr:table>
> >         </tr:column>
> >     </tr:table>
> >
> >
> > Whereas this does indeed work (the same, but using h:dataTable instead of
> tr:table):
> >
> >     <h:dataTable value="#{fichaOperadorBean.attributes }" var="attribute">
> >         <h:column>
> >             <tr:outputText value="#{attribute.xnomatrb}"/>
> >         </h:column>
> >         <h:column rendered="#{attribute.xtipdado eq 'S' or
> attribute.xtipdado eq 'L'}">
> >             <h:dataTable value="#{attribute.attributeData}"
> var="attributeData">
> >                 <h:column>
> >                     <tr:outputText value="#{ attributeData.xvalor}" />
> >                 </h:column>
> >             </h:dataTable>
> >         </h:column>
> >     </h:dataTable>
> >
> > Is there another intended way to use tr:table for this to work?
> >
> >
>
>

Re: [Trinidad] tr:table within tr:table

Posted by Brian Smith <un...@gmail.com>.
Try wrapping your nested table inside of a detailStamp facet instead of a
column

    <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
        <tr:column>
            <tr:outputText value="#{attribute.xnomatrb }"/>
        </tr:column>
        <f:facet name="detailStamp">
            <tr:table value="#{attribute.attributeData }"
var="attributeData">
                <tr:column>
                    <tr:outputText value="#{attributeData.xvalor}" />
                </tr:column>
            </tr:table>
        </f:facet>
    </tr:table>

Here is a demo
http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx

Here is the source
http://www.irian.at/trinidad-demo/faces/components/table_nested.jspx.source

On 5/4/07, Francisco Passos <fr...@gmail.com> wrote:
>
> Hello there.
>
> I'm attempting to use a tr:table within another one and the second one
> doesn't show. I'm trying to present a list of values, where each value may
> have a list of different values. So I was aiming for something like
>
> Column 1 | Column 2
> ---------|-----------
> Value 1  | SubValue 1
>          | SubValue 2
> ---------|-----------
> Value 2  | SubValue 3
>          | SubValue 4
>          | SubValue 5
>
> This does not work:
>
>     <tr:table value="#{fichaOperadorBean.attributes}" var="attribute">
>         <tr:column>
>             <tr:outputText value="#{attribute.xnomatrb }"/>
>         </tr:column>
>         <tr:column rendered="#{attribute.xtipdado eq 'S' or
> attribute.xtipdado eq 'L'}">
>             <tr:table value="#{attribute.attributeData }"
> var="attributeData">
>                 <tr:column>
>                     <tr:outputText value="#{attributeData.xvalor}" />
>                 </tr:column>
>             </tr:table>
>         </tr:column>
>     </tr:table>
>
>
> Whereas this does indeed work (the same, but using h:dataTable instead of
> tr:table):
>
>     <h:dataTable value="#{fichaOperadorBean.attributes }" var="attribute">
>         <h:column>
>             <tr:outputText value="#{attribute.xnomatrb}"/>
>         </h:column>
>         <h:column rendered="#{attribute.xtipdado eq 'S' or
> attribute.xtipdado eq 'L'}">
>             <h:dataTable value="#{attribute.attributeData}"
> var="attributeData">
>                 <h:column>
>                     <tr:outputText value="#{ attributeData.xvalor}" />
>                 </h:column>
>             </h:dataTable>
>         </h:column>
>     </h:dataTable>
>
> Is there another intended way to use tr:table for this to work?
>
>