details.jsp 22.3 KB
Newer Older
Matija Obreza's avatar
Matija Obreza committed
1 2 3 4 5 6 7 8
<!DOCTYPE html>

<%@include file="/WEB-INF/jsp/init.jsp"%>

<html>
<head>
<title><spring:message code="accession.page.profile.title" arguments="${accession.accessionName}" argumentSeparator="|" /></title>
</head>
9
<body typeof="germplasm:GermplasmAccession">
Matija Obreza's avatar
Matija Obreza committed
10
	<h1>
Matija Obreza's avatar
Matija Obreza committed
11 12
		<span property="dwc:catalogNumber"><c:out value="${accession.accessionName}" /></span>
		<small property="dwc:institutionCode" datatype="germplasmType:wiewsInstituteID"><c:out value="${accession.instituteCode}" /></small>
Matija Obreza's avatar
Matija Obreza committed
13
	</h1>
Matija Obreza's avatar
Updates  
Matija Obreza committed
14

Matija Obreza's avatar
Matija Obreza committed
15
	<div class="main-col-header acn">
Matija Obreza's avatar
Matija Obreza committed
16
		<div class="sel" x-aid="${accession.id}">
17
			<a class="add" href=""><spring:message code="selection.add" arguments="${accession.accessionName}" /></a> <a class="remove" href=""><spring:message code="selection.remove"
Matija Obreza's avatar
Matija Obreza committed
18
					arguments="${accession.accessionName}" /></a>
Matija Obreza's avatar
Matija Obreza committed
19
		</div>
Matija Obreza's avatar
Matija Obreza committed
20
	</div>
Matija Obreza's avatar
Matija Obreza committed
21

Matija Obreza's avatar
Matija Obreza committed
22
	<c:if test="${accession.inTrust eq true}">
Matija Obreza's avatar
Matija Obreza committed
23
		<div class="alert alert-info">
Matija Obreza's avatar
Updates  
Matija Obreza committed
24 25
			<spring:message code="accession.inTrust.true" />
		</div>
Matija Obreza's avatar
Matija Obreza committed
26
	</c:if>
Matija Obreza's avatar
Updates  
Matija Obreza committed
27

Matija Obreza's avatar
Matija Obreza committed
28
	<c:if test="${accession.inSvalbard eq true}">
Matija Obreza's avatar
Matija Obreza committed
29
		<div class="alert alert-info">
Matija Obreza's avatar
Updates  
Matija Obreza committed
30 31
			<spring:message code="accession.inSvalbard.true" />
		</div>
Matija Obreza's avatar
Matija Obreza committed
32
	</c:if>
Matija Obreza's avatar
Updates  
Matija Obreza committed
33

Matija Obreza's avatar
Matija Obreza committed
34
	<c:if test="${accession.mlsStatus eq true}">
Matija Obreza's avatar
Matija Obreza committed
35
		<div class="alert alert-info">
Matija Obreza's avatar
Updates  
Matija Obreza committed
36 37
			<spring:message code="accession.mlsStatus.true" />
		</div>
Matija Obreza's avatar
Matija Obreza committed
38
	</c:if>
Matija Obreza's avatar
Matija Obreza committed
39 40 41 42 43 44

	<c:if test="${accession.historic eq true}">
		<div class="alert alert-warning">
			<spring:message code="accession.this-is-a-historic-entry" />
		</div>
	</c:if>
Matija Obreza's avatar
Matija Obreza committed
45
	
Matija Obreza's avatar
Matija Obreza committed
46
<%--
47
	<c:if test="${accession.availability eq false}">
Matija Obreza's avatar
Matija Obreza committed
48 49 50 51
		<div class="alert alert-warning">
			<spring:message code="accession.not-available-for-distribution" />
		</div>
	</c:if>
Matija Obreza's avatar
Matija Obreza committed
52 53 54 55 56 57
	
	<c:if test="${accession.availability eq true}">
		<div class="alert alert-info">
			<spring:message code="accession.available-for-distribution" />
		</div>
	</c:if>
Matija Obreza's avatar
Matija Obreza committed
58
--%>	
Matija Obreza's avatar
Matija Obreza committed
59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80
<%--
<div itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
	<a href="<c:url value="/wiews/${accession.institute.code}" />" itemprop="url">
	<span itemprop="title" dir="ltr">${accession.institute.fullName}</span>
	</a> ›
	<span itemprop="child" itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
		<a href="<c:url value="/wiews/${accession.institute.code}/data" />" itemprop="url">
		<span itemprop="title" dir="ltr">Accessions</span>
		</a> ›
		<span itemprop="child" itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
			<a title="<spring:message code="accession.taxonomy-at-institute" arguments="${accession.taxonomy.genus}|||${accession.institute.code}" argumentSeparator="|||" />" href="<c:url value="/wiews/${accession.institute.code}/t/${accession.taxonomy.genus}" />" itemprop="url">
			<span itemprop="title" dir="ltr">${accession.taxonomy.genus}</span>
			</a> ›
			<span itemprop="child" itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
				<a title="<spring:message code="accession.taxonomy-at-institute" arguments="${accession.taxonomy.genus} ${accession.taxonomy.species}|||${accession.institute.code}" argumentSeparator="|||" />" href="<c:url value="/wiews/${accession.institute.code}/t/${accession.taxonomy.genus}/${accession.taxonomy.species}" />" itemprop="url">
				<span itemprop="title" dir="ltr">${accession.taxonomy.genus} ${accession.taxonomy.species}</span>
				</a>
			</span>
		</span>
	</span>
</div>
--%>
Matija Obreza's avatar
Matija Obreza committed
81

82
	<div class="pseudo-right-col col-md-3">
83
		<c:if test="${accessionGeo.latitude ne null and accessionGeo.longitude ne null}">
84 85
		
		<div class="crop-location" itemscope itemtype="http://schema.org/GeoCoordinates">
Matija Obreza's avatar
Matija Obreza committed
86
		 <h3><spring:message code="accession.collecting.site" /></h3>
87
	        <div id="map" class="map-container"></div>
Matija Obreza's avatar
Matija Obreza committed
88 89 90
	        
	        <table class="map-data">  
	        <tr>
Matija Obreza's avatar
Matija Obreza committed
91
	            <td><spring:message code="filter.geo.latitude" />:</td>
Matija Obreza's avatar
Matija Obreza committed
92 93
	            <td><c:out value="${accessionGeo.latitude}" /></td>
	          </tr><tr>
Matija Obreza's avatar
Matija Obreza committed
94
	            <td><spring:message code="filter.geo.longitude" />:</td>
Matija Obreza's avatar
Matija Obreza committed
95 96 97 98 99 100 101 102 103 104
	            <td><c:out value="${accessionGeo.longitude}" /></td>
	          </tr><tr>
	            <td><spring:message code="accession.elevation" />:</td>
	            <td><c:out value="${accessionGeo.elevation}" /></td>
	          </tr>
	         </table>
	      </div>
		</c:if>
	</div>
	
Matija Obreza's avatar
Matija Obreza committed
105 106 107
	<div class="crop-details">
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.holdingInstitute" /></div>
Matija Obreza's avatar
Matija Obreza committed
108
				<div class="col-xs-8"><a property="dwc:institutionCode" href="<c:url value="/wiews/${accession.instituteCode}" />"> <c:out value="${accession.institute.fullName}" />
Matija Obreza's avatar
Matija Obreza committed
109 110 111 112 113 114 115 116 117 118
				</a></div>
			</div>
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.holdingCountry" /></div>
				<div class="col-xs-8"><a href="<c:url value="/geo/${accession.institute.country.code3}" />"><c:out value="${accession.institute.country.getName(pageContext.response.locale)}" /></a></div>
			</div>
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.accessionName" /></div>
				<div class="col-xs-8"><c:out value="${accession.accessionName}" /></div>
			</div>
Matija Obreza's avatar
Matija Obreza committed
119

Matija Obreza's avatar
Matija Obreza committed
120
			<c:if test="${crops ne null}">
Matija Obreza's avatar
Matija Obreza committed
121 122 123
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.crop" /></div>
					<div class="col-xs-8"><c:forEach items="${crops}" var="crop">
124
							<a href="<c:url value="/c/${crop.shortName}" />"><c:out value="${crop.getName(pageContext.response.locale)}" /></a>
Matija Obreza's avatar
Matija Obreza committed
125 126
						</c:forEach></div>
				</div>
127
			</c:if>
Matija Obreza's avatar
Matija Obreza committed
128

Matija Obreza's avatar
Matija Obreza committed
129
			<c:if test="${accession.countryOfOrigin ne null}">
Matija Obreza's avatar
Matija Obreza committed
130 131 132 133 134
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.origin" /></div>
					<div class="col-xs-8"><img src="<c:url value="${cdnFlagsUrl}" />/${accession.origin.toUpperCase()}.png" /> <a href="<c:url value="/geo/${accession.origin}" />"> <c:out value="${accession.countryOfOrigin.getName(pageContext.response.locale)}" />
					</a></div>
				</div>
Matija Obreza's avatar
Matija Obreza committed
135
			</c:if>
Matija Obreza's avatar
Matija Obreza committed
136

Matija Obreza's avatar
Matija Obreza committed
137 138
			<div class="row">
				<div class="col-xs-4"><spring:message code="taxonomy.genus" /></div>
139
				<div class="col-xs-8" property="dwc:genus"><a href="<c:url value="/acn/t/${accession.taxonomy.genus}" />"><span dir="ltr" class="sci-name" ><c:out value="${accession.taxonomy.genus}" /></span></a></div>
Matija Obreza's avatar
Matija Obreza committed
140 141 142
			</div>
			<div class="row">
				<div class="col-xs-4"><spring:message code="taxonomy.species" /></div>
143
				<div class="col-xs-8"><a href="<c:url value="/acn/t/${accession.taxonomy.genus}/${accession.taxonomy.species}" />"><span class="sci-name" dir="ltr"><c:out value="${accession.taxonomy.genus} ${accession.taxonomy.species}" /></span></a>
Matija Obreza's avatar
Matija Obreza committed
144
					<br />
145
					<a href="<c:url value="/wiews/${accession.institute.code}/t/${accession.taxonomy.genus}/${accession.taxonomy.species}" />"><spring:message code="accession.taxonomy-at-institute" arguments="${accession.taxonomy.genus} ${accession.taxonomy.species}|||${accession.institute.code}" argumentSeparator="|||" /></a>
Matija Obreza's avatar
Matija Obreza committed
146 147 148 149
				</div>
			</div>
			<div class="row">
				<div class="col-xs-4"><spring:message code="taxonomy.taxonName" /></div>
150
				<div class="col-xs-8"><span dir="ltr" class="sci-name" ><c:out value="${accession.taxonomy.taxonName}" /></span></div>
Matija Obreza's avatar
Matija Obreza committed
151
			</div>
152

Matija Obreza's avatar
Matija Obreza committed
153 154 155 156
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.sampleStatus" /></div>
				<div class="col-xs-8" property="germplasm:biologicalStatus"><spring:message code="accession.sampleStatus.${accession.sampleStatus}" /></div>
			</div>
157

Matija Obreza's avatar
Matija Obreza committed
158 159
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.storage" /></div>
160 161 162 163 164
				<div class="col-xs-8">
					<c:forEach items="${accession.stoRage}" var="storage">
						<div><spring:message code="accession.storage.${storage}" /></div>
					</c:forEach>
				</div>
Matija Obreza's avatar
Matija Obreza committed
165
			</div>
166

Matija Obreza's avatar
Matija Obreza committed
167 168 169 170
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.availability" /></div>
				<div class="col-xs-8"><spring:message code="accession.availability.${accession.availability}" /></div>
			</div>
171
			
Matija Obreza's avatar
Matija Obreza committed
172 173 174
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.otherNames" /></div>
				<div class="col-xs-8">
175 176 177 178
				<c:forEach items="${accessionAliases}" var="accessionAlias">
					<div>
						<c:out value="${accessionAlias.name}" />
						<c:if test="${accessionAlias.instCode != ''}">
179
							<a href="<c:url value="/wiews/${accessionAlias.instCode}" />">
180 181 182
							${accessionAlias.instCode}
							</a>
						</c:if>
183 184 185
						<c:if test="${accessionAlias.usedBy != ''}">
							${accessionAlias.usedBy}
						</c:if>
186 187 188 189 190 191
						<c:if test="${accessionAlias.lang != ''}">
							<c:out value="${accessionAlias.lang}" />
						</c:if>
						<spring:message code="accession.aliasType.${accessionAlias.aliasType}" />
					</div>			
				</c:forEach>
Matija Obreza's avatar
Matija Obreza committed
192 193
				</div>
			</div>
Matija Obreza's avatar
Matija Obreza committed
194
			
Matija Obreza's avatar
Matija Obreza committed
195 196 197
			<div class="row">
				<div class="col-xs-4"><spring:message code="accession.duplSite" /></div>
				<div class="col-xs-8"><c:forEach items="${accession.duplSite.split('[;,]')}" var="duplSite">
198
					<div><spring:message code="${duplSite}" /></div>
Matija Obreza's avatar
Matija Obreza committed
199 200
				</c:forEach></div>
			</div>
201
			
Matija Obreza's avatar
Updates  
Matija Obreza committed
202 203

			<c:if test="${accessionExchange ne null}">
Matija Obreza's avatar
Matija Obreza committed
204 205
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.donor.institute" /></div>
206 207 208 209 210 211
					<div class="col-xs-8">
						<c:if test="${accessionExchange.donorInstitute eq null}">
						${accessionExchange.donorName}
						</c:if>
						${accessionExchange.donorInstitute}
					</div>
Matija Obreza's avatar
Matija Obreza committed
212 213 214 215 216
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.donor.accessionNumber" /></div>
					<div class="col-xs-8">${accessionExchange.accNumbDonor}</div>
				</div>
217 218 219 220 221 222 223 224 225 226 227
        
              <c:if test="${accession.uuid ne null}">
                <div class="row text-muted">
                  <div class="col-xs-4"><spring:message code="accession.uuid" /></div>
                  <div class="col-xs-8"><span property="dc:identifier">urn:uuid:<c:out value="${accession.uuid}" /></span></div>
                </div>
                <div class="row">
                  <div class="col-xs-4"><spring:message code="accession.purl" /></div>
                  <div class="col-xs-8"><span property="dc:identifier"><a href="https://purl.org/germplasm/id/${accession.uuid}"><c:out value="https://purl.org/germplasm/id/${accession.uuid}" /></a></span></div>
                </div>
              </c:if>
Matija Obreza's avatar
Updates  
Matija Obreza committed
228 229 230
			</c:if>

			<c:if test="${accessionCollect ne null}">
Matija Obreza's avatar
Matija Obreza committed
231 232 233 234 235 236
				<h4><spring:message code="accession.collecting" /></h4>
				
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.institute" /></div>
					<div class="col-xs-8">${accessionCollect.collCode}</div>
				</div>
237
				<c:if test="${accessionCollect.collName ne null}">
Matija Obreza's avatar
Matija Obreza committed
238 239 240 241 242
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.institute" /></div>
					<div class="col-xs-8">${accessionCollect.collName}
					${accessionCollect.collInstAddress}</div>
				</div>
243
				</c:if>
Matija Obreza's avatar
Matija Obreza committed
244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.mission" /></div>
					<div class="col-xs-8"><c:out value="${accessionCollect.collMissId}" /></div>
<%--				<div class="col-xs-8"><a href="<c:url value="/collectingmission"><c:param name="collMissId" value="${accessionCollect.collMissId}" /></c:url>"><c:out value="${accessionCollect.collMissId}" /></a></div> --%>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.date" /></div>
					<div class="col-xs-8">${accessionCollect.collDate}</div>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.number" /></div>
					<div class="col-xs-8">${accessionCollect.collNumb}</div>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.site" /></div>
					<div class="col-xs-8">${accessionCollect.collSite}</div>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.source" /></div>
					<div class="col-xs-8"><spring:message code="accession.collectingSource.${accessionCollect.collSrc}" /></div>
				</div>
Matija Obreza's avatar
Updates  
Matija Obreza committed
265 266 267
			</c:if>

			<c:if test="${accessionBreeding ne null}">
Matija Obreza's avatar
Matija Obreza committed
268 269 270 271 272 273 274 275 276 277
				<h4><spring:message code="accession.breeding" /></h4>

				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.breederCode" /></div>
					<div class="col-xs-8">${accessionBreeding.breederCode}</div>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.pedigree" /></div>
					<div class="col-xs-8">${accessionBreeding.pedigree}</div>
				</div>
Matija Obreza's avatar
Updates  
Matija Obreza committed
278 279 280
			</c:if>


281
			<c:if test="${accessionGeo ne null}">
Matija Obreza's avatar
Matija Obreza committed
282 283
				<h4><spring:message code="accession.geo" /></h4>

284
				<c:if test="${accessionCollect.collSite ne null}">
Matija Obreza's avatar
Matija Obreza committed
285 286 287 288
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.collecting.site" /></div>
					<div class="col-xs-8">${accessionCollect.collSite}</div>
				</div>
289
				</c:if>
290
				<c:if test="${accessionGeo.latitude ne null}">
Matija Obreza's avatar
Matija Obreza committed
291 292 293 294
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.geolocation" /></div>
					<div class="col-xs-8">${accessionGeo.latitude}, ${accessionGeo.longitude}</div>
				</div>
Matija Obreza's avatar
Matija Obreza committed
295 296
				</c:if>
				<c:if test="${accessionGeo.elevation ne null}">
Matija Obreza's avatar
Matija Obreza committed
297 298 299 300
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.elevation" /></div>
					<div class="col-xs-8">${accessionGeo.elevation}<span class="uom">m</span></div>
				</div>
Matija Obreza's avatar
Matija Obreza committed
301
				</c:if>
Matija Obreza's avatar
Matija Obreza committed
302 303 304 305 306 307 308 309
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.geo.datum" /></div>
					<div class="col-xs-8">${accessionGeo.datum}</div>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.geo.method" /></div>
					<div class="col-xs-8">${accessionGeo.method}</div>
				</div>
310
				<c:if test="${accessionGeo.uncertainty ne null}">
Matija Obreza's avatar
Matija Obreza committed
311 312 313 314
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.geo.uncertainty" /></div>
					<div class="col-xs-8">${accessionGeo.uncertainty}<span class="uom">m</span></div>
				</div>
315
				</c:if>
Matija Obreza's avatar
Updates  
Matija Obreza committed
316 317
			</c:if>

318
<security:authorize access="isAuthenticated()">
Matija Obreza's avatar
Matija Obreza committed
319
			<!-- WorldClim.org -->
Matija Obreza's avatar
DS2  
Matija Obreza committed
320
			<c:if test="${worldclimJson ne null}">
Matija Obreza's avatar
Matija Obreza committed
321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385
				<h4><spring:message code="worldclim.monthly.title" /></h4>

				<!-- Charts -->
				<div class="row">
					<div class="col-xs-12 col-sm-6">
						<h5><spring:message code="worldclim.monthly.temperatures.title" /></h5>
						<div id="temperatureChart" style="height:150px;"></div>
					</div>
					<div class="col-xs-12 col-sm-6">
						<h5><spring:message code="worldclim.monthly.precipitation.title" /></h5>
						<div id="precipitationChart" style="height:150px;"></div>
					</div>
				</div>
				
				<!-- Data -->
				<div class="row">
					<div class="col-sm-offset-4 col-sm-8 col-xs-12">
						<div class="row">
						<c:forEach var="i" begin="0" end="11">
							<div class="col-xs-1 text-right"><strong><c:out value="${jspHelper.monthShortNames(pageContext.response.locale)[i]}" /></strong></div>
						</c:forEach>
						</div>
					</div>
				</div>
				<div class="row">
					<div class="col-sm-4 col-xs-12"><spring:message code="worldclim.monthly.tempMin" /></div>
					<div class="col-sm-8 col-xs-12">
						<div class="row">
							<c:forEach var="i" begin="0" end="11">
									<div class="col-xs-1 text-right"><fmt:formatNumber value="${worldclimJson.tempMin[i]}" /></div>
							</c:forEach>
						</div>
					</div>
				</div>
				<div class="row">
					<div class="col-sm-4 col-xs-12"><spring:message code="worldclim.monthly.tempMean" /></div>
					<div class="col-sm-8 col-xs-12">
						<div class="row">
							<c:forEach var="i" begin="0" end="11">
									<div class="col-xs-1 text-right"><fmt:formatNumber value="${worldclimJson.tempMean[i]}" /></div>
							</c:forEach>
						</div>
					</div>
				</div>
				<div class="row">
					<div class="col-sm-4 col-xs-12"><spring:message code="worldclim.monthly.tempMax" /></div>
					<div class="col-sm-8 col-xs-12">
						<div class="row">
							<c:forEach var="i" begin="0" end="11">
									<div class="col-xs-1 text-right"><fmt:formatNumber value="${worldclimJson.tempMax[i]}" /></div>
							</c:forEach>
						</div>
					</div>
				</div>
				<div class="row">
					<div class="col-sm-4 col-xs-12"><spring:message code="worldclim.monthly.precipitation" /></div>
					<div class="col-sm-8 col-xs-12">
						<div class="row">
							<c:forEach var="i" begin="0" end="11">
									<div class="col-xs-1 text-right"><fmt:formatNumber value="${worldclimJson.precipitation[i]}" /></div>
							</c:forEach>
						</div>
					</div>
				</div>
				
Matija Obreza's avatar
Matija Obreza committed
386
				<%-- Needs work 
Matija Obreza's avatar
Matija Obreza committed
387 388 389 390 391 392 393
				<h4><spring:message code="worldclim.other-climate" /></h4>
				<c:forEach items="${worldclimJson.other.keySet()}" var="worldclimDescriptor">
				<div class="row">
					<div class="col-xs-4"><c:out value="${worldclimDescriptor.title}" /></div>
					<div class="col-xs-8"><fmt:formatNumber value="${worldclimJson.other[worldclimDescriptor]}" /><span class="uom">${worldclimDescriptor.uom}</span></div>
				</div>
				</c:forEach>
Matija Obreza's avatar
Matija Obreza committed
394
				--%>
Matija Obreza's avatar
Matija Obreza committed
395
			</c:if>
396
</security:authorize>
Matija Obreza's avatar
Matija Obreza committed
397

398
			<c:if test="${svalbardData ne null}">
Matija Obreza's avatar
Matija Obreza committed
399
				<h4><spring:message code="accession.svalbard-data" /></h4>
Matija Obreza's avatar
Matija Obreza committed
400

Matija Obreza's avatar
Matija Obreza committed
401 402 403 404
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.svalbard-data.taxonomy" /></div>
					<div class="col-xs-8">${svalbardData.taxonomy}</div>
				</div>
Matija Obreza's avatar
Matija Obreza committed
405

Matija Obreza's avatar
Matija Obreza committed
406 407 408 409 410 411 412 413 414 415 416 417
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.svalbard-data.depositDate" /></div>
					<div class="col-xs-8">${svalbardData.depositDate}</div>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.svalbard-data.boxNumber" /></div>
					<div class="col-xs-8">${svalbardData.boxNumber}</div>
				</div>
				<div class="row">
					<div class="col-xs-4"><spring:message code="accession.svalbard-data.quantity" /></div>
					<div class="col-xs-8">${svalbardData.quantity}</div>
				</div>
Matija Obreza's avatar
Matija Obreza committed
418

Matija Obreza's avatar
Matija Obreza committed
419
			</c:if>
Matija Obreza's avatar
Matija Obreza committed
420

Matija Obreza's avatar
Matija Obreza committed
421 422 423 424 425 426 427 428 429 430 431
	
			<c:if test="${fn:length(accessionRemarks) gt 0}">		
				<h4><spring:message code="accession.remarks" /></h4>
			</c:if>
			<c:forEach items="${accessionRemarks}" var="accessionRemark">
				<div class="row">
					<div class="col-xs-4"><c:out value="${accessionRemark.fieldName}" /></div>
					<div class="col-xs-8"><c:out value="${accessionRemark.remark}" /></div>
				</div>
			</c:forEach>
	</div>
Matija Obreza's avatar
Matija Obreza committed
432

Matija Obreza's avatar
Updates  
Matija Obreza committed
433

Matija Obreza's avatar
Matija Obreza committed
434
	<c:if test="${methods.size() gt 0}">
Matija Obreza's avatar
Matija Obreza committed
435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452

		<div class="crop-details">
			<h4>
				<spring:message code="accession.methods" />
			</h4>
			<c:forEach items="${methods}" var="method" varStatus="status">
				<div class="row targeted" id="method${method.id}">
					<div class="col-xs-6 col-sm-4"><c:out value="${method.parameter.title}" /></div>
					<div class="col-xs-6 col-sm-4"><c:forEach items="${methodValues[method.id]}" var="val">
							<div>
								<c:out value="${method.decode(val.value)}" />
								<span class="uom"><c:out value="${method.unit}" /></span> <sup><a href="#metadata-${val.experimentId}"><c:out value="${val.experimentId}" /></a></sup>
							</div>
						</c:forEach></div>
					<div class="col-xs-12 col-sm-4"><c:out value="${method.method}" /></div>
				</div>
			</c:forEach>
		</div>
Matija Obreza's avatar
Matija Obreza committed
453 454 455
	</c:if>

	<c:if test="${metadatas.size() gt 0}">
456
		<h4>
Matija Obreza's avatar
Matija Obreza committed
457
			<spring:message code="accession.metadatas" />
458
		</h4>
Matija Obreza's avatar
Matija Obreza committed
459
		<ul class="funny-list">
Matija Obreza's avatar
Matija Obreza committed
460 461 462 463 464 465
			<c:forEach items="${metadatas}" var="metadata" varStatus="status">
				<li class="clearfix targeted ${status.count % 2 == 0 ? 'even' : 'odd'}" id="metadata-${metadata.id}">
					<div class="show pull-left">
						<sup><c:out value="${metadata.id}" /></sup> <a href="<c:url value="/data/view/${metadata.id}" />"><c:out value="${metadata.title}" /></a>
					</div>
					<div class="pull-right">
Matija Obreza's avatar
Matija Obreza committed
466
						<c:out value="${metadata.instituteCode}" />
Matija Obreza's avatar
Matija Obreza committed
467 468 469 470 471 472
					</div>
					<div class="pull-right">
						<c:out value="${metadata.description}" />
					</div>
				</li>
			</c:forEach>
Matija Obreza's avatar
Matija Obreza committed
473
		</ul>
Matija Obreza's avatar
Matija Obreza committed
474
	</c:if>
Matija Obreza's avatar
Matija Obreza committed
475 476 477 478 479
	
	
	
	<div class="audit-info">
		<c:if test="${accession.lastModifiedBy ne null}"><spring:message code="audit.lastModifiedBy" arguments="${jspHelper.userFullName(accession.lastModifiedBy)}" /></c:if>
480
		<local:prettyTime date="${accession.lastModifiedDate}" locale="${pageContext.response.locale}" />
Matija Obreza's avatar
Matija Obreza committed
481
	</div>
482 483

	<content tag="javascript">
484 485 486
	<c:if test="${accessionGeo ne null and accessionGeo.latitude ne null}">
		<script type="text/javascript">
				jQuery(document).ready(function() {
Matija Obreza's avatar
Matija Obreza committed
487
					var map = L.map('map').setView([${accessionGeo.latitude}, ${accessionGeo.longitude}], 2);
488 489 490 491 492 493 494 495 496 497
					L.tileLayer('https://otile{s}-s.mqcdn.com/tiles/1.0.0/sat/{z}/{x}/{y}.png', {
					    attribution: "MapQuest",
					    styleId: 22677,
					    subdomains: ['1','2','3','4'],
					    opacity: 0.6
					}).addTo(map);
					var marker = L.marker([${accessionGeo.latitude}, ${accessionGeo.longitude}]).addTo(map);
				});
		</script>
	</c:if>
498
<security:authorize access="isAuthenticated()">
Matija Obreza's avatar
DS2  
Matija Obreza committed
499
	<c:if test="${worldclimJson ne null}">
Matija Obreza's avatar
Matija Obreza committed
500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550
		<script type="text/javascript">
			var monthNames = ${jspHelper.toJson(jspHelper.monthShortNames(pageContext.response.locale))};
			var worldclim = ${jspHelper.toJson(worldclimJson)};
			function arrayToData(array) {
				var ret=[];
				for (var i=0; i<12; i++) {
					ret[i]=[i, array[i]];
				}
				return ret;
			}
			var temperatureChart = [
				{ label: "Temperatures", data: arrayToData(worldclim.tempMean), lines: { show: true }, color: "rgb(255,50,50)" },
				{ id: "max", data: arrayToData(worldclim.tempMax), lines: { show: true, lineWidth: 0, fill: false }, color: "rgb(255,50,50)" },
				{ id: "min", data: arrayToData(worldclim.tempMin), lines: { show: true, lineWidth: 0, fill: 0.2 }, color: "rgb(255,50,50)", fillBetween: "max" }
			];
			var precipitationChart = [
				{ label: "Precipitation", data: arrayToData(worldclim.precipitation), bars: { show: true, align: "center" }, color: "rgb(50,50,255)" }
			];
			var temperaturePlot = $.plot($("#temperatureChart"), temperatureChart, {
				xaxis: { tickLength: 0, tickFormatter: function(v, o) {
					return monthNames[v];
				} },
				yaxis: {
						tickFormatter: function (v) {
							return v + " °C";
						}
				},
				legend: { show: false }
			});
			var precipitationPlot = $.plot($("#precipitationChart"), precipitationChart, {
				xaxis: { tickLength: 0, tickFormatter: function(v, o) {
					return monthNames[v];
				} },
				yaxis: {
						tickFormatter: function (v) {
							return v + " mm";
						}
				},
				legend: { show: false }
			});
			$( window ).resize(function() {
				precipitationPlot.resize();
				precipitationPlot.setupGrid();
				precipitationPlot.draw();
				
				temperaturePlot.resize();
				temperaturePlot.setupGrid();
				temperaturePlot.draw();
			});
		</script>
	</c:if>
551 552
</security:authorize>

553
	<script type="text/javascript">
Matija Obreza's avatar
Matija Obreza committed
554
		<%@include file="/WEB-INF/jsp/wiews/ga.jsp"%>
Matija Obreza's avatar
Matija Obreza committed
555
		_pageDim = { institute: '${accession.instituteCode}', genus: '${accession.taxonomy.genus}' };
Matija Obreza's avatar
Matija Obreza committed
556
	</script>
557
	</content>
Matija Obreza's avatar
Matija Obreza committed
558 559
</body>
</html>