Hi All,
I want to display a range of values in a drop down list using velocity template.
I hav written the following code ...
#foreach($p in $productMap) // productMap is a Map containg all vaues
<td class="qty">
#set ($minQty = 1)
#set ($qtyCount = ${p.inventory.NetTotal})
#set ($counter = [$minQty..${qtyCount }])
<select id="cartItems[$cartItemIndex].quantity" name="cartItems[$cartItemIndex].quantity">
#foreach( $index in $counter )
<option #if($cartItem.quantity == $index)selected #end value="${index}">${index}</option>
#end
</select>
#springShowErrors("<br>" "req")
#else
$cartItem.quantity
#end
</td>
#end
The result of this code is that its not showing range of values in the drop down list ... its coming empty....
Please let me know if anybody knows abt the answer.......