JSLT tags & <display:table>
Am using <display:column>
, i want to have a column i.e:"id " to be displayed and to be linkable. everything is ok until now but i want to display the link dynamic according to conditions.
<c:choose>
<c:when test="${courseList.partner.area.country.id == user_country }">
<display:column property="id" escapeXml="fals开发者_如何学编程e" sortable="true"
url="/editCourse.html}" paramId="id" paramProperty="id"
titleKey="course.id"/>
</c:when>
<c:otherwise>
<display:column property="id" escapeXml="false" sortable="true" sortName="id"/>
</c:otherwise>
</c:choose>
The output is supposed to be list of ids displayed that are not linkable and the others are linkable. The problem is if the first row starting with linkable id so the rest row are displayed also linkable even if they doesn't fit the condition and vice versa.
Could you please advice me how can i solve it ?
Thanks in Advance
Assuming you are using Displaytag, have a look at the decorators
Possibly you can use any of the already existing decorators i e AutolinkColumnDecorator http://www.displaytag.org/1.2/displaytag/apidocs/index.html
or you might have too right your own implementation, which is fairly easy, look at http://www.displaytag.org/1.2/tut_decorators.html
精彩评论