Java Reference
In-Depth Information
Figure 3.5:
Adding View and Delete links
To send the contact ID as a parameter for the View and Delete links,
add a column to the table like this:
<d:column title="Action">
<s:link beanclass="stripesbook.action.ContactListActionBean"
event="view">
<s:param name="contactId" value="${contact.id}"/>
View
</s:link>
|
<s:link beanclass="stripesbook.action.ContactListActionBean"
event="delete">
<s:param name="contactId" value="${contact.id}"/>
Delete
</s:link>
</d:column>
Clicking either link first calls
setContactId(Integer)
on the action bean
and supplies the contact ID as a parameter. It then calls the event
handler.
Search WWH ::
Custom Search