File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

indexed property problem

 
danny liu
Ranch Hand
Posts: 185
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here is a little bit tricky case. The form structure is as below.
claimForm
----- claimInfo
--- replacementInfo
---replacementList
-----replacementItem
.....
-----replacementItem

I want display the replacement items with full path.

Here is my nested approach

<nested:root name="claimForm">
<nested:nest property="claimInfo.replacementInfo" >
<nested efine id="dropdown" property="manufacturerList"/>
<nested:iterate property="replacementList" id="replacementItem">

<tr><td>
<nested:select name="replacementItem" property="manufacturer" indexed="true">
<option value="">Select Manufacturer</option>
<html ptions collection="dropdown" property="manufacturerName"/>
</nested:select>
</td>
<td>
<nested:text name="replacementItem" property="model" indexed="true"/>
</td>
<td>
<nested:text name="replacementItem" property="seer" indexed="true"/>
</td></tr>


</nested:iterate>

</nested:nest>
</nested:root>

Here is the result



<tr><td>
<select name="replacementItem[0].manufacturer"><option value="">Select Manufacturer</option>
<option value="American Standard">American Standard</option>
<option value="Bryant">Bryant</option>
<option value="Carrier">Carrier</option>
<option value="Goodman">Goodman</option>
<option value="Lennox">Lennox</option>
<option value="Other">Other</option>
<option value="Rheem">Rheem</option>
<option value="Ruud">Ruud</option>
<option value="Trane">Trane</option>
<option value="York">York</option></select>
</td>
<td>
<input type="text" name="replacementItem[0].model" value="">
</td>
<td>
<input type="text" name="replacementItem[0].seer" value="">
</td></tr>




<tr><td>
<select name="replacementItem[1].manufacturer"><option value="">Select Manufacturer</option>
<option value="American Standard">American Standard</option>
<option value="Bryant">Bryant</option>
<option value="Carrier">Carrier</option>
<option value="Goodman">Goodman</option>
<option value="Lennox">Lennox</option>
<option value="Other">Other</option>
<option value="Rheem">Rheem</option>
<option value="Ruud">Ruud</option>
<option value="Trane">Trane</option>
<option value="York">York</option></select>
</td>
<td>
<input type="text" name="replacementItem[1].model" value="">
</td>
<td>
<input type="text" name="replacementItem[1].seer" value="">
</td></tr>




<tr><td>
<select name="replacementItem[2].manufacturer"><option value="">Select Manufacturer</option>
<option value="American Standard">American Standard</option>
<option value="Bryant">Bryant</option>
<option value="Carrier">Carrier</option>
<option value="Goodman">Goodman</option>
<option value="Lennox">Lennox</option>
<option value="Other">Other</option>
<option value="Rheem">Rheem</option>
<option value="Ruud">Ruud</option>
<option value="Trane">Trane</option>
<option value="York">York</option></select>
</td>
<td>
<input type="text" name="replacementItem[2].model" value="">
</td>
<td>
<input type="text" name="replacementItem[2].seer" value="">
</td></tr>




<tr><td>
<select name="replacementItem[3].manufacturer"><option value="">Select Manufacturer</option>
<option value="American Standard">American Standard</option>
<option value="Bryant">Bryant</option>
<option value="Carrier">Carrier</option>
<option value="Goodman">Goodman</option>
<option value="Lennox">Lennox</option>
<option value="Other">Other</option>
<option value="Rheem">Rheem</option>
<option value="Ruud">Ruud</option>
<option value="Trane">Trane</option>
<option value="York">York</option></select>
</td>
<td>
<input type="text" name="replacementItem[3].model" value="">
</td>
<td>
<input type="text" name="replacementItem[3].seer" value="">
</td></tr>


Could someone figure out why the full path cannot be generated?

Thanks.

Dan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic