You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by Michał Szwaczko <mi...@wirelabs.net> on 2016/08/27 18:59:11 UTC
Accessing tags with repeaters
Hello
I have a simple repeater that dynamically assemblies a row of a table from default components (labels, panels, buttons etc) The row is part of the dataview.
RepeatingView row = new RepeatingView("row");
[in Dataview's populateItem I set components]
row.add(some_component);
row.add(some_other_component);
[..]
Markup is this:
<tr wicket:id="dataview">
<td wicket:id="row"></td>
<tr>
Now, in the dataview's onPopulateItem, i'd like to set attribute to the <td> tag based on some property of the populated object.
Sadly there's no markup id for the <td>, nor any accessible component in that tag that I could handle with AttributeAppender.
Is there any other way to do that? Can I somehow get the <td> handle?
Regards
Michal
Re: Accessing tags with repeaters
Posted by Michał Szwaczko <mi...@wirelabs.net>.
On Sat, 27 Aug 2016 21:08:13 +0200
Martin Grigorov <ma...@gmail.com> wrote:
> Hi,
>
> Please ask questions in users@ mailing list.
> dev@ is for discussing changes in Wicket itself.
> Thank you!
Oops, sorry. Meant to send to users but somehow ... ;)
Michal
Re: Accessing tags with repeaters
Posted by Martin Grigorov <ma...@gmail.com>.
Hi,
Please ask questions in users@ mailing list.
dev@ is for discussing changes in Wicket itself.
Thank you!
On Aug 27, 2016 8:59 PM, "Michał Szwaczko" <mi...@wirelabs.net> wrote:
> Hello
>
> I have a simple repeater that dynamically assemblies a row of a table from
> default components (labels, panels, buttons etc) The row is part of the
> dataview.
>
>
> RepeatingView row = new RepeatingView("row");
>
> [in Dataview's populateItem I set components]
> row.add(some_component);
> row.add(some_other_component);
> [..]
>
>
>
> Markup is this:
>
> <tr wicket:id="dataview">
> <td wicket:id="row"></td>
> <tr>
>
> Now, in the dataview's onPopulateItem, i'd like to set attribute to the
> <td> tag based on some property of the populated object.
>
> Sadly there's no markup id for the <td>, nor any accessible component in
> that tag that I could handle with AttributeAppender.
> Is there any other way to do that? Can I somehow get the <td> handle?
>
> Regards
> Michal
>
>
>
>
>