form requires dynamic radio button list

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

form requires dynamic radio button list

Qbyte Consulting
Hi,

The examples of using the tapestry radio button are all static. I need the
radio buttons to build from a dynamic list (in this case of locations)
presumably using a loop, something like this:

         <t:form>
                <t:radiogroup value="locality">
                    <t:loop t:source="localities" t:value="locality">
                        <t:radio t:value="locality" t:label="prop:locality"
t:mixins="jquery/bind" t:bind.event="venueChanged"
t:bind.eventType="change" t:bind.zone="venueChooserZone"/>
                    </t:loop>
                </t:radiogroup>

But this does not work!? Note that I also want to fire an event when the
user selects a radio button to rerender the rest of the form in response to
a change of location.

Any ideas how to solve this please?

John
Reply | Threaded
Open this post in threaded view
|

Re: form requires dynamic radio button list

Chris Poulsen
It seems like you are using the locality property for everything (selected
value and loop variable) maybe that is the source of your problem?

On Thu, Feb 5, 2015 at 6:40 AM, John Coleman <[hidden email]>
wrote:

> Hi,
>
> The examples of using the tapestry radio button are all static. I need the
> radio buttons to build from a dynamic list (in this case of locations)
> presumably using a loop, something like this:
>
>          <t:form>
>                 <t:radiogroup value="locality">
>                     <t:loop t:source="localities" t:value="locality">
>                         <t:radio t:value="locality" t:label="prop:locality"
> t:mixins="jquery/bind" t:bind.event="venueChanged"
> t:bind.eventType="change" t:bind.zone="venueChooserZone"/>
>                     </t:loop>
>                 </t:radiogroup>
>
> But this does not work!? Note that I also want to fire an event when the
> user selects a radio button to rerender the rest of the form in response to
> a change of location.
>
> Any ideas how to solve this please?
>
> John
>
Reply | Threaded
Open this post in threaded view
|

Re: form requires dynamic radio button list

Thiago H de Paula Figueiredo
In reply to this post by Qbyte Consulting
On Thu, 05 Feb 2015 03:40:18 -0200, John Coleman  
<[hidden email]> wrote:

> Hi,

Hi!


> But this does not work!?

What do you mean by "does not work"? This is too vague for us to provide  
any useful answer. In addition, the Java code related to the template  
snippet is also needed to know what's happening.


--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]