institute.tag 1.46 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11
<%@ tag description="Display FAO institute data" pageEncoding="UTF-8"%>
<%@ tag body-content="empty"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ taglib prefix="security"
	uri="http://www.springframework.org/security/tags"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ attribute name="institute" required="true"
	type="org.genesys2.server.model.impl.FaoInstitute"%>

<div class="genesys-mini genesys-institute">
12
	<div class="title ${institute.current ? '' : 'not-current'}">
13 14 15
		<a href="<c:url value="/wiews/${institute.code}" />"><c:out
				value="${institute.code}" /></a>
		<c:out value="${institute.fullName}" />
16
		<span class="acronym"><c:out value="${institute.acronym}" /></span>
17 18 19 20 21 22 23
	</div>
	<div class="accessionCount">
		<c:choose>
			<c:when test="${institute.accessionCount gt 0}">
				<spring:message code="faoInstitutes.stat.accessionCount" />
				<a href="<c:url value="/wiews/${institute.code}/data" />"><fmt:formatNumber value="${institute.accessionCount}" /></a>
			</c:when>
24 25 26 27 28 29
			<c:when test="${! institute.current}">
				<!-- Link to active -->
				<a href="<c:url value="/wiews/${faoInstitute.vCode}" />">
					<spring:message code="faoInstitute.view-current-institute" arguments="${institute.vCode}" />
				</a>
			</c:when>
30
			<c:otherwise>
31
				<spring:message code="faoInstitute.no-accessions-registered" />
32 33 34 35
			</c:otherwise>
		</c:choose>
	</div>
</div>