You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Tom Götz <to...@decoded.de> on 2016/04/08 08:12:06 UTC

DataTable with subrows

Hi there,

is there a clean way to have „subrows“ in a DataTable? I want to do something like that: http://www.bootply.com/GGAMvot45f <http://www.bootply.com/GGAMvot45f>

The only solution I found yet involves writing into the output stream directly (as shown here: http://www.javased.com/?post=3822324 <http://www.javased.com/?post=3822324>). Has anybody done something like that already? Any pointers welcome.

Cheers,
   Tom



Re: DataTable with subrows

Posted by Ernesto Reinaldo Barreiro <re...@gmail.com>.
Hi Tom,

I haven't tried this but maybe you could...

1- Make your own Item that implements IMarkupResourceStreamProvider... That
provides same markup of DataTable <tr> plus and additional TR repeater (to
be used for children). I.e

 <tr wicket:id="rows" class="clickable" data-toggle="collapse" id="row1"
data-target=".row1">
            <td></td>
 </tr>
        <tr wicket:id="addtionalRepeater class="collapse row1">
            <td>- child row</td>
        </tr>

2- Then override as in the example you mention but add your  extra repeater

Just an idea... which might not work at all

On Fri, Apr 8, 2016 at 8:12 AM, Tom Götz <to...@decoded.de> wrote:

> Hi there,
>
> is there a clean way to have „subrows“ in a DataTable? I want to do
> something like that: http://www.bootply.com/GGAMvot45f <
> http://www.bootply.com/GGAMvot45f>
>
> The only solution I found yet involves writing into the output stream
> directly (as shown here: http://www.javased.com/?post=3822324 <
> http://www.javased.com/?post=3822324>). Has anybody done something like
> that already? Any pointers welcome.
>
> Cheers,
>    Tom
>
>
>


-- 
Regards - Ernesto Reinaldo Barreiro

Re: DataTable with subrows

Posted by Tom Götz <to...@decoded.de>.
Thanks for the pointers Martin and Ernesto,

TreeTable looks promising, I’ll play around with that one and see how far I can bend it ;-)

Cheers,
   Tom


> On 08.04.2016, at 08:57, Martin Grigorov <mg...@apache.org> wrote:
> 
> Hi Tom,
> 
> The closest we have is TreeTable component:
> http://examples7x.wicket.apache.org/tree/wicket/bookmarkable/org.apache.wicket.examples.tree.TableTreePage
> If this is not exactly what you need then you can create your own one by
> using GridView.
> ​



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: DataTable with subrows

Posted by Martin Grigorov <mg...@apache.org>.
Hi Tom,

The closest we have is TreeTable component:
http://examples7x.wicket.apache.org/tree/wicket/bookmarkable/org.apache.wicket.examples.tree.TableTreePage
If this is not exactly what you need then you can create your own one by
using GridView.
​