struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Lowe <mark.l...@talk21.com>
Subject Re: nested iterators and writing back to the form
Date Fri, 06 Feb 2004 14:31:48 GMT

The second list just needs the have the name of the object that 
contains the list.

At the moment you've got

orders.getOrders()

which i assume is wrong. If each order contains an iterate-able object 
then that's what you want to reference in the nested one.

i think you want

<logic:iterate id="element" name="allocationOrder" property="orders">
	<logic:iterate id="subElement" name="element" property="orderDetails">

Notice the bean that is cast via the id attibute is what is referenced, 
and then the iterate-able  structure in the property attribute.

orders[0].getOrderDetails();

Cheers Mark

On 6 Feb 2004, at 13:32, Michael Wiles wrote:

>
> I have a nested list...
>
> something like:
>
> <logic:iterate property="orders" name="allocationOrder"
> 		id="element">
> ..
> ..
> ..
> 	<logic:iterate property="orderDetails" name="orders"
> 		id="subElement">
> ..
> 			<html:text name="subElement" property="qty"/>
> ..
> 	</logic:iterate>
> </logic:iterate>
>
> How do I map the html:text tag back to the form?
>
> Without anything extra added to the form, it doesn't work.
>
>
>
>
> Read our disclaimer at: http://www.picknpay.co.za/email-disclaimer.htm
> If you don't have web access, the disclaimer can be mailed to you on 
> request.
> Disclaimer requests to be sent to it-security@pnp.co.za
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Mime
View raw message