I am a newbie iam using jstl and spring,here i am having a jsp which fetch all the products like car,bike,cycle from database and i retrived all the products added in arraylist using jstl.Now in jsp i am having certain option like getlicense, getproduct on click of getlicense it should navigate to the method getlicense in controller from there it should navigate to getlicense.jsp.But the method getlicense in controller i have to pass certain values(like license information,license no) of my products (car,bike,cycle). Please help me resolving this issue
This my jsp here in license option i need to pass the values of partnumber
to a method in modelandview
<td class="listData" valign="top" width="14%">${suites.partNumber}</td>
<td class="listData" valign="top" width="20%">${suites.assetDescription}</td>
<td class="listData" valign="top" width="20$">${suites.assetNumber}</td>
<td class="listData" valign="top" width="10$">
<c:choose>
<c:when test="${empty suites.licenseType}">
<c:out value="Not Available" />
</c:when>
<c:otherwise>
<c:out value="${suites.licenseType}" />
</c:otherwise>
</c:choose>
</td>
<td class="listData" valign="top" width="15%">
<a href="/webapp/servicerequest.create_SR.framework">
Submit Service Request
</a>
</td>
<td class="listData" valign="top" width="11%">${suites.registeredDate}</td>
<td class="listData" valign="top" width="11%">${suites.endDate}</td>
<td class="listData" valign="top" width="10%" align="center">
<a href="/webapp/licensing/licenseOptions.jsp">
<img src="/licensing/images/1443_LICENSE_OPTIONS.gif" alt="License Options" border="0"/>
</a>
<a href="/webapp/ecommerce.add_item.framework?PART_NUMBER=${suites.partNumber}&entitlementId=${suites.entitlementId}&ITEM_TYPE=${suites.assetType}&QUANTITY=1&RETURN_URL=/licensing/getSuiteList.sp&attribName=ENTITLEMENT_ID&licenseType=${suites.licenseType}">
<img src="/licensing/images/purchase.gif" alt="Purchase More Seats" border="0"/>
</a>
</td>
What I understand from your problem is you need to access the PART_NUMBER passed in URL in your controller method.
For this you should add one parameter in your controller method to access the variable. Like below mentioned code.
Hope this helps you. If you have any other questions then be more specific.
Cheers.