Skip to content

Instantly share code, notes, and snippets.

@akahn786
Created October 6, 2009 16:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save akahn786/203188 to your computer and use it in GitHub Desktop.
Save akahn786/203188 to your computer and use it in GitHub Desktop.
<s:layout-component name="body">
<p>item details</p>
<c:if test="${not empty actionBean.item}">
<c:choose>
<c:when test="${actionBean.item.lost == true}">
<s:link beanclass="org.stripesbook.quickstart.action.ItemListActionBean" event="listLost">Go Back to the List</s:link><br/>
</c:when>
<c:otherwise>
<s:link beanclass="org.stripesbook.quickstart.action.ItemListActionBean" event="listFound">Go Back to the List</s:link><br/>
</c:otherwise>
</c:choose>
<br/>
Item: ${actionBean.item.id}<br/>
<br/>
<div id="itemFlagged">
<s:link beanclass="org.stripesbook.quickstart.action.ItemDetailActionBean"
event="flagItem" onclick="return flagItem(this);">
<s:param name="item" value="${actionBean.item.id}"/>
Flag Item
</s:link>
</div>
<p/>
<c:if test="${actionBean.hasPreviousItemId}">
<s:link beanclass="org.stripesbook.quickstart.action.ItemDetailActionBean">
<s:param name="item" value="${actionBean.item.id-1}"/>
Previous item
</s:link>
</c:if>
<c:if test="${actionBean.hasNextItemId}">
<s:link beanclass="org.stripesbook.quickstart.action.ItemDetailActionBean">
<s:param name="item" value="${actionBean.item.id+1}"/>
Next item
</s:link>
</c:if>
<p/>
<br/>
<s:link beanclass="org.stripesbook.quickstart.action.ContactSamaritanFormActionBean">
<s:param name="item" value="${actionBean.item.id}"/>
Contact User<br/>
</s:link>
date: <fmt:formatDate type="date" dateStyle="full" value="${actionBean.item.dateFound}"/><br/>
name: ${actionBean.item.name}<br/>
description: ${actionBean.item.desc}<br/>
city: ${actionBean.item.city.name}<br/>
state: ${actionBean.item.state.name}<br/>
<c:if test="${actionBean.item.imageExists}">
<img src="resources/${actionBean.item.id}.jpg" width=500 />
</c:if>
</c:if>
</s:layout-component>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment