struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paolo Niccolò Giubelli <paoloniccolo.giube...@itestense.it>
Subject Re: Retrieve an hashtable entry within a jsp using struts tag and a bean as the key
Date Tue, 01 Jul 2008 20:25:43 GMT
Ok, I used jstl and now it works!
Here's the code (it's changed since the first post, so don't compare it):

<logic:iterate id="category" name="pannelloForm" 
property="highLevelCategories">
<div>
<h5><bean:write name="category" property="name"/> </h5>
<c:set var="subcategories" 
value="${pannelloForm.highLevelCategoriesChildren[category.id]}"></c:set>
<ul>
<c:forEach var="subcategory" items="${subcategories}">
<li>${subcategory.contenuto.name}</li>
</c:forEach>
</ul>
</div>
</logic:iterate>

where:
- pannelloForm is the ActionForm bean
- highLevelCategories is an ArrayList<FProductCategory>
- highLevelCategoriesChildren is an 
Hashtable<Integer,ArrayList<FProductCategory>>



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


Mime
View raw message