1
|
<?xml version="1.0"?>
|
2
|
<!--
|
3
|
* '$RCSfile$'
|
4
|
* Authors: Matt Jones
|
5
|
* Copyright: 2000 Regents of the University of California and the
|
6
|
* National Center for Ecological Analysis and Synthesis
|
7
|
* For Details: http://www.nceas.ucsb.edu/
|
8
|
*
|
9
|
* '$Author: walker $'
|
10
|
* '$Date: 2015-05-07 12:22:56 -0700 (Thu, 07 May 2015) $'
|
11
|
* '$Revision: 9199 $'
|
12
|
*
|
13
|
* This program is free software; you can redistribute it and/or modify
|
14
|
* it under the terms of the GNU General Public License as published by
|
15
|
* the Free Software Foundation; either version 2 of the License, or
|
16
|
* (at your option) any later version.
|
17
|
*
|
18
|
* This program is distributed in the hope that it will be useful,
|
19
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
20
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
21
|
* GNU General Public License for more details.
|
22
|
*
|
23
|
* You should have received a copy of the GNU General Public License
|
24
|
* along with this program; if not, write to the Free Software
|
25
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
26
|
*
|
27
|
* This is an XSLT (http://www.w3.org/TR/xslt) stylesheet designed to
|
28
|
* convert an XML file that is valid with respect to the eml-dataset.dtd
|
29
|
* module of the Ecological Metadata Language (EML) into an HTML format
|
30
|
* suitable for rendering with modern web browsers.
|
31
|
-->
|
32
|
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
|
33
|
|
34
|
|
35
|
<xsl:output method="html" encoding="UTF-8"
|
36
|
doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
|
37
|
doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
|
38
|
indent="yes" />
|
39
|
|
40
|
<xsl:template match="dataset" mode="dataset">
|
41
|
<xsl:choose>
|
42
|
<xsl:when test="references!=''">
|
43
|
<xsl:variable name="ref_id" select="references"/>
|
44
|
<xsl:variable name="references" select="$ids[@id=$ref_id]" />
|
45
|
<xsl:for-each select="$references">
|
46
|
<xsl:call-template name="datasetmixed"/>
|
47
|
</xsl:for-each>
|
48
|
</xsl:when>
|
49
|
<xsl:otherwise>
|
50
|
<xsl:call-template name="datasetmixed"/>
|
51
|
</xsl:otherwise>
|
52
|
</xsl:choose>
|
53
|
|
54
|
</xsl:template>
|
55
|
|
56
|
<xsl:template name="datasetmixed">
|
57
|
|
58
|
<!-- citation -->
|
59
|
<xsl:for-each select=".">
|
60
|
<xsl:call-template name="datasetcitation" />
|
61
|
</xsl:for-each>
|
62
|
|
63
|
<h4>General</h4>
|
64
|
<!-- put in the title -->
|
65
|
<xsl:if test="./title">
|
66
|
<xsl:for-each select="./title">
|
67
|
<xsl:call-template name="resourcetitle">
|
68
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
69
|
<xsl:with-param name="ressecondColStyle" select="$secondColStyle"/>
|
70
|
</xsl:call-template>
|
71
|
</xsl:for-each>
|
72
|
</xsl:if>
|
73
|
<!-- put in the short name -->
|
74
|
<xsl:if test="shortName">
|
75
|
<xsl:for-each select="./shortName">
|
76
|
<xsl:call-template name="resourceshortName">
|
77
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
78
|
<xsl:with-param name="ressecondColStyle" select="$secondColStyle"/>
|
79
|
</xsl:call-template>
|
80
|
</xsl:for-each>
|
81
|
</xsl:if>
|
82
|
<!-- put in the identifier and system that the ID belongs to -->
|
83
|
<xsl:if test="../@packageId">
|
84
|
<xsl:for-each select="../@packageId">
|
85
|
<xsl:choose>
|
86
|
<xsl:when test="$docid != ''" >
|
87
|
<!-- use docid parameter when we have it -->
|
88
|
<xsl:call-template name="identifier">
|
89
|
<xsl:with-param name="packageID" select="$docid"/>
|
90
|
<xsl:with-param name="system" select="../@system"/>
|
91
|
<xsl:with-param name="IDfirstColStyle" select="$firstColStyle"/>
|
92
|
<xsl:with-param name="IDsecondColStyle" select="$secondColStyle"/>
|
93
|
</xsl:call-template>
|
94
|
</xsl:when>
|
95
|
<xsl:otherwise>
|
96
|
<xsl:call-template name="identifier">
|
97
|
<xsl:with-param name="packageID" select="../@packageId"/>
|
98
|
<xsl:with-param name="system" select="../@system"/>
|
99
|
<xsl:with-param name="IDfirstColStyle" select="$firstColStyle"/>
|
100
|
<xsl:with-param name="IDsecondColStyle" select="$secondColStyle"/>
|
101
|
</xsl:call-template>
|
102
|
</xsl:otherwise>
|
103
|
</xsl:choose>
|
104
|
</xsl:for-each>
|
105
|
</xsl:if>
|
106
|
<!-- put in the alternate identifiers -->
|
107
|
<xsl:if test="keywordSet">
|
108
|
<xsl:for-each select="alternateIdentifier">
|
109
|
<xsl:call-template name="resourcealternateIdentifier">
|
110
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
111
|
<xsl:with-param name="ressecondColStyle" select="$secondColStyle"/>
|
112
|
</xsl:call-template>
|
113
|
</xsl:for-each>
|
114
|
</xsl:if>
|
115
|
<!-- put in the text of the abstract-->
|
116
|
<xsl:if test="./abstract">
|
117
|
<xsl:for-each select="./abstract">
|
118
|
<xsl:call-template name="resourceabstract">
|
119
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
120
|
<xsl:with-param name="ressecondColStyle" select="$secondColStyle"/>
|
121
|
</xsl:call-template>
|
122
|
</xsl:for-each>
|
123
|
</xsl:if>
|
124
|
<!-- put in the purpose of the dataset-->
|
125
|
<xsl:if test="./purpose">
|
126
|
<xsl:for-each select="./purpose">
|
127
|
<xsl:call-template name="datasetpurpose">
|
128
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
129
|
<xsl:with-param name="ressecondColStyle" select="$secondColStyle"/>
|
130
|
</xsl:call-template>
|
131
|
</xsl:for-each>
|
132
|
</xsl:if>
|
133
|
<!-- put in the keyword sets -->
|
134
|
<xsl:if test="keywordSet">
|
135
|
<div class="row-fluid">
|
136
|
<div class="control-group">
|
137
|
<label class="control-label">
|
138
|
<xsl:text>Keywords</xsl:text>
|
139
|
</label>
|
140
|
<div class="controls controls-well">
|
141
|
<xsl:for-each select="keywordSet">
|
142
|
<xsl:call-template name="resourcekeywordSet" >
|
143
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
144
|
<xsl:with-param name="ressecondColStyle" select="$secondColStyle"/>
|
145
|
</xsl:call-template>
|
146
|
</xsl:for-each>
|
147
|
</div>
|
148
|
</div>
|
149
|
</div>
|
150
|
</xsl:if>
|
151
|
|
152
|
<!-- put in the publication date -->
|
153
|
<xsl:if test="./pubDate">
|
154
|
<xsl:for-each select="pubDate">
|
155
|
<xsl:call-template name="resourcepubDate" >
|
156
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
157
|
</xsl:call-template>
|
158
|
</xsl:for-each>
|
159
|
</xsl:if>
|
160
|
|
161
|
<!-- put in the language -->
|
162
|
<xsl:if test="./language">
|
163
|
<xsl:for-each select="language">
|
164
|
<xsl:call-template name="resourcelanguage" >
|
165
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
166
|
</xsl:call-template>
|
167
|
</xsl:for-each>
|
168
|
</xsl:if>
|
169
|
|
170
|
<!-- put in the series -->
|
171
|
<xsl:if test="./series">
|
172
|
<xsl:for-each select="series">
|
173
|
<xsl:call-template name="resourceseries" >
|
174
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
175
|
</xsl:call-template>
|
176
|
</xsl:for-each>
|
177
|
</xsl:if>
|
178
|
|
179
|
|
180
|
|
181
|
<!-- create a second easy access table listing the data entities -->
|
182
|
<xsl:if test="dataTable|spatialRaster|spatialVector|storedProcedure|view|otherEntity">
|
183
|
<xsl:if test="$withEntityLinks='1' or $displaymodule = 'printall'">
|
184
|
<xsl:call-template name="datasetentity"/>
|
185
|
</xsl:if>
|
186
|
</xsl:if>
|
187
|
|
188
|
|
189
|
|
190
|
<h4>People and Associated Parties</h4>
|
191
|
|
192
|
<!-- add in the creators -->
|
193
|
<xsl:if test="creator">
|
194
|
<div class="control-group">
|
195
|
<label class="control-label">
|
196
|
Data Set Creators
|
197
|
</label>
|
198
|
<div class="controls controls-well">
|
199
|
<xsl:for-each select="creator">
|
200
|
|
201
|
<xsl:variable name="absolutePath" >
|
202
|
<xsl:for-each select="ancestor-or-self::*">
|
203
|
<xsl:text>/</xsl:text>
|
204
|
<xsl:value-of select="local-name()" />
|
205
|
</xsl:for-each>
|
206
|
</xsl:variable>
|
207
|
<xsl:variable name="index" select="position()" />
|
208
|
<div>
|
209
|
<xsl:attribute name="resource">#xpointer(<xsl:value-of select="$absolutePath"/>[<xsl:value-of select="$index"/>])</xsl:attribute>
|
210
|
<xsl:attribute name="type">party</xsl:attribute>
|
211
|
<xsl:call-template name="party">
|
212
|
<xsl:with-param name="partyfirstColStyle" select="$firstColStyle"/>
|
213
|
<xsl:with-param name="partysecondColStyle" select="$secondColStyle"/>
|
214
|
</xsl:call-template>
|
215
|
</div>
|
216
|
</xsl:for-each>
|
217
|
</div>
|
218
|
</div>
|
219
|
</xsl:if>
|
220
|
|
221
|
<!-- add in the contacts -->
|
222
|
<xsl:if test="contact">
|
223
|
<div class="control-group">
|
224
|
<label class="control-label">Data Set Contacts</label>
|
225
|
<div class="controls controls-well">
|
226
|
<xsl:for-each select="contact">
|
227
|
<xsl:variable name="absolutePath" >
|
228
|
<xsl:for-each select="ancestor-or-self::*">
|
229
|
<xsl:text>/</xsl:text>
|
230
|
<xsl:value-of select="local-name()" />
|
231
|
</xsl:for-each>
|
232
|
</xsl:variable>
|
233
|
<xsl:variable name="index" select="position()" />
|
234
|
<div>
|
235
|
<xsl:attribute name="resource">#xpointer(<xsl:value-of select="$absolutePath"/>[<xsl:value-of select="$index"/>])</xsl:attribute>
|
236
|
<xsl:attribute name="type">party</xsl:attribute>
|
237
|
<xsl:call-template name="party">
|
238
|
<xsl:with-param name="partyfirstColStyle" select="$firstColStyle"/>
|
239
|
<xsl:with-param name="partysecondColStyle" select="$secondColStyle"/>
|
240
|
</xsl:call-template>
|
241
|
</div>
|
242
|
|
243
|
</xsl:for-each>
|
244
|
</div>
|
245
|
</div>
|
246
|
</xsl:if>
|
247
|
|
248
|
<!-- add in the associatedParty -->
|
249
|
<xsl:if test="associatedParty">
|
250
|
<div class="control-group">
|
251
|
<label class="control-label">Associated Parties</label>
|
252
|
<div class="controls controls-well">
|
253
|
<xsl:for-each select="associatedParty">
|
254
|
<xsl:variable name="absolutePath" >
|
255
|
<xsl:for-each select="ancestor-or-self::*">
|
256
|
<xsl:text>/</xsl:text>
|
257
|
<xsl:value-of select="local-name()" />
|
258
|
</xsl:for-each>
|
259
|
</xsl:variable>
|
260
|
<xsl:variable name="index" select="position()" />
|
261
|
<div>
|
262
|
<xsl:attribute name="resource">#xpointer(<xsl:value-of select="$absolutePath"/>[<xsl:value-of select="$index"/>])</xsl:attribute>
|
263
|
<xsl:attribute name="type">party</xsl:attribute>
|
264
|
<xsl:call-template name="party">
|
265
|
<xsl:with-param name="partyfirstColStyle" select="$firstColStyle"/>
|
266
|
<xsl:with-param name="partysecondColStyle" select="$secondColStyle"/>
|
267
|
</xsl:call-template>
|
268
|
</div>
|
269
|
</xsl:for-each>
|
270
|
</div>
|
271
|
</div>
|
272
|
|
273
|
</xsl:if>
|
274
|
|
275
|
<!-- add in the metadataProviders using a two column table -->
|
276
|
<xsl:if test="metadataProvider">
|
277
|
<div class="control-group">
|
278
|
<label class="control-label">Metadata Providers</label>
|
279
|
<div class="controls controls-well">
|
280
|
<xsl:for-each select="metadataProvider">
|
281
|
<xsl:variable name="absolutePath" >
|
282
|
<xsl:for-each select="ancestor-or-self::*">
|
283
|
<xsl:text>/</xsl:text>
|
284
|
<xsl:value-of select="local-name()" />
|
285
|
</xsl:for-each>
|
286
|
</xsl:variable>
|
287
|
<xsl:variable name="index" select="position()" />
|
288
|
<div>
|
289
|
<xsl:attribute name="resource">#xpointer(<xsl:value-of select="$absolutePath"/>[<xsl:value-of select="$index"/>])</xsl:attribute>
|
290
|
<xsl:attribute name="type">party</xsl:attribute>
|
291
|
<xsl:call-template name="party">
|
292
|
<xsl:with-param name="partyfirstColStyle" select="$firstColStyle"/>
|
293
|
<xsl:with-param name="partysecondColStyle" select="$secondColStyle"/>
|
294
|
</xsl:call-template>
|
295
|
</div>
|
296
|
</xsl:for-each>
|
297
|
</div>
|
298
|
</div>
|
299
|
</xsl:if>
|
300
|
|
301
|
<!-- add in the publishers using a two column table -->
|
302
|
<xsl:if test="publisher">
|
303
|
<div class="control-group">
|
304
|
<label class="control-label">Data Set Publishers</label>
|
305
|
<div class="controls controls-well">
|
306
|
<xsl:for-each select="publisher">
|
307
|
<xsl:variable name="absolutePath" >
|
308
|
<xsl:for-each select="ancestor-or-self::*">
|
309
|
<xsl:text>/</xsl:text>
|
310
|
<xsl:value-of select="local-name()" />
|
311
|
</xsl:for-each>
|
312
|
</xsl:variable>
|
313
|
<xsl:variable name="index" select="position()" />
|
314
|
<div>
|
315
|
<xsl:attribute name="resource">#xpointer(<xsl:value-of select="$absolutePath"/>[<xsl:value-of select="$index"/>])</xsl:attribute>
|
316
|
<xsl:attribute name="type">party</xsl:attribute>
|
317
|
<xsl:call-template name="party">
|
318
|
<xsl:with-param name="partyfirstColStyle" select="$firstColStyle"/>
|
319
|
<xsl:with-param name="partysecondColStyle" select="$secondColStyle"/>
|
320
|
</xsl:call-template>
|
321
|
</div>
|
322
|
</xsl:for-each>
|
323
|
</div>
|
324
|
</div>
|
325
|
</xsl:if>
|
326
|
|
327
|
<!-- add in the coverage info -->
|
328
|
<!-- <h4>Context</h4> -->
|
329
|
|
330
|
<!-- add in the geographic coverage info -->
|
331
|
<div class="row-fluid">
|
332
|
<xsl:if test="./coverage/geographicCoverage">
|
333
|
<xsl:for-each select="./coverage/geographicCoverage">
|
334
|
<xsl:call-template name="geographicCoverage">
|
335
|
<xsl:with-param name="firstColStyle" select="$firstColStyle"/>
|
336
|
<xsl:with-param name="secondColStyle" select="$secondColStyle"/>
|
337
|
</xsl:call-template>
|
338
|
</xsl:for-each>
|
339
|
</xsl:if>
|
340
|
</div>
|
341
|
<!-- add in the temporal coverage info -->
|
342
|
<div class="row-fluid">
|
343
|
<xsl:if test="./coverage/temporalCoverage">
|
344
|
<xsl:for-each select="./coverage/temporalCoverage">
|
345
|
<xsl:call-template name="temporalCoverage">
|
346
|
<xsl:with-param name="firstColStyle" select="$firstColStyle"/>
|
347
|
<xsl:with-param name="secondColStyle" select="$secondColStyle"/>
|
348
|
</xsl:call-template>
|
349
|
</xsl:for-each>
|
350
|
</xsl:if>
|
351
|
</div>
|
352
|
<!-- add in the taxonomic coverage info -->
|
353
|
<div class="row-fluid">
|
354
|
<xsl:if test="./coverage/taxonomicCoverage">
|
355
|
<xsl:for-each select="./coverage/taxonomicCoverage">
|
356
|
<xsl:call-template name="taxonomicCoverage">
|
357
|
<xsl:with-param name="firstColStyle" select="$firstColStyle"/>
|
358
|
<xsl:with-param name="secondColStyle" select="$secondColStyle"/>
|
359
|
</xsl:call-template>
|
360
|
</xsl:for-each>
|
361
|
</xsl:if>
|
362
|
</div>
|
363
|
|
364
|
<!-- add in the method info -->
|
365
|
<h4>Sampling, Processing and Quality Control Methods</h4>
|
366
|
|
367
|
<div class="row-fluid">
|
368
|
<xsl:if test="./methods">
|
369
|
<xsl:for-each select="./methods">
|
370
|
<xsl:call-template name="datasetmethod">
|
371
|
<xsl:with-param name="methodfirstColStyle" select="$firstColStyle"/>
|
372
|
<xsl:with-param name="methodsecondColStyle" select="$secondColStyle"/>
|
373
|
</xsl:call-template>
|
374
|
</xsl:for-each>
|
375
|
</xsl:if>
|
376
|
</div>
|
377
|
|
378
|
<h4>Data Set Usage Rights</h4>
|
379
|
|
380
|
<!-- add in the intellectiual rights info -->
|
381
|
<div class="row-fluid">
|
382
|
<xsl:if test="intellectualRights">
|
383
|
<xsl:for-each select="intellectualRights">
|
384
|
<xsl:call-template name="resourceintellectualRights">
|
385
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
386
|
<xsl:with-param name="ressecondColStyle" select="$secondColStyle"/>
|
387
|
</xsl:call-template>
|
388
|
</xsl:for-each>
|
389
|
</xsl:if>
|
390
|
</div>
|
391
|
|
392
|
<!-- add in the access control info -->
|
393
|
<div class="row-fluid">
|
394
|
<xsl:if test="access">
|
395
|
<xsl:for-each select="access">
|
396
|
<xsl:call-template name="access">
|
397
|
<xsl:with-param name="accessfirstColStyle" select="$firstColStyle"/>
|
398
|
<xsl:with-param name="accesssecondColStyle" select="$secondColStyle"/>
|
399
|
</xsl:call-template>
|
400
|
</xsl:for-each>
|
401
|
</xsl:if>
|
402
|
</div>
|
403
|
</xsl:template>
|
404
|
|
405
|
<xsl:template name="datasetresource">
|
406
|
<div class="row-fluid">
|
407
|
<xsl:call-template name="resource">
|
408
|
<xsl:with-param name="resfirstColStyle" select="$firstColStyle"/>
|
409
|
<xsl:with-param name="ressubHeaderStyle" select="$subHeaderStyle"/>
|
410
|
</xsl:call-template>
|
411
|
</div>
|
412
|
</xsl:template>
|
413
|
|
414
|
|
415
|
<xsl:template name="datasetpurpose">
|
416
|
<xsl:for-each select="purpose">
|
417
|
<div class="control-group">
|
418
|
<label class="control-label"><xsl:text>Purpose</xsl:text></label>
|
419
|
<div class="controls">
|
420
|
 
|
421
|
<xsl:call-template name="text">
|
422
|
<xsl:with-param name="textfirstColStyle" select="$firstColStyle"/>
|
423
|
</xsl:call-template>
|
424
|
</div>
|
425
|
</div>
|
426
|
</xsl:for-each>
|
427
|
</xsl:template>
|
428
|
|
429
|
<xsl:template name="datasetmaintenance">
|
430
|
<xsl:for-each select="maintenance">
|
431
|
<div class="control-group">
|
432
|
<label class="control-label"><xsl:text>Maintenance</xsl:text></label>
|
433
|
<div class="controls">
|
434
|
<xsl:call-template name="mantenancedescription"/>
|
435
|
<div class="control-group">
|
436
|
<label class="control-label">Frequency</label>
|
437
|
<div class="controls" >
|
438
|
<xsl:value-of select="maintenanceUpdateFrequency"/>
|
439
|
</div>
|
440
|
</div>
|
441
|
<xsl:call-template name="datasetchangehistory"/>
|
442
|
</div>
|
443
|
</div>
|
444
|
</xsl:for-each>
|
445
|
</xsl:template>
|
446
|
|
447
|
<xsl:template name="mantenancedescription">
|
448
|
<xsl:for-each select="description">
|
449
|
<div class="control-group">
|
450
|
<label class="control-label">Description</label>
|
451
|
<div class="controls">
|
452
|
<xsl:call-template name="text">
|
453
|
<xsl:with-param name="textfirstColStyle" select="$firstColStyle"/>
|
454
|
</xsl:call-template>
|
455
|
</div>
|
456
|
</div>
|
457
|
</xsl:for-each>
|
458
|
</xsl:template>
|
459
|
|
460
|
<xsl:template name="datasetchangehistory">
|
461
|
<xsl:if test="changeHistory">
|
462
|
<div class="control-group">
|
463
|
<label class="control-label">History</label>
|
464
|
<div class="controls">
|
465
|
<xsl:for-each select="changeHistory">
|
466
|
<xsl:call-template name="historydetails"/>
|
467
|
</xsl:for-each>
|
468
|
</div>
|
469
|
</div>
|
470
|
</xsl:if>
|
471
|
</xsl:template>
|
472
|
|
473
|
<xsl:template name="historydetails">
|
474
|
<div class="control-group">
|
475
|
<label class="control-label">scope</label>
|
476
|
<div class="controls">
|
477
|
<xsl:value-of select="changeScope"/>
|
478
|
</div>
|
479
|
</div>
|
480
|
<div class="control-group">
|
481
|
<label class="control-label">old value</label>
|
482
|
<div class="controls">
|
483
|
<xsl:value-of select="oldValue"/>
|
484
|
</div>
|
485
|
</div>
|
486
|
<div class="control-group">
|
487
|
<label class="control-label">change date</label>
|
488
|
<div class="controls">
|
489
|
<xsl:value-of select="changeDate"/>
|
490
|
</div>
|
491
|
</div>
|
492
|
<xsl:if test="comment and normalize-space(comment)!=''">
|
493
|
<div class="control-group">
|
494
|
<label class="control-label">comment</label>
|
495
|
<div class="controls">
|
496
|
<xsl:value-of select="comment"/>
|
497
|
</div>
|
498
|
</div>
|
499
|
</xsl:if>
|
500
|
</xsl:template>
|
501
|
|
502
|
<xsl:template name="datasetcontact">
|
503
|
<div class="control-group">
|
504
|
<label class="control-label"><xsl:text>Contact</xsl:text></label>
|
505
|
<div class="controls">
|
506
|
<xsl:for-each select="contact">
|
507
|
<xsl:call-template name="party">
|
508
|
<xsl:with-param name="partyfirstColStyle" select="$firstColStyle"/>
|
509
|
</xsl:call-template>
|
510
|
</xsl:for-each>
|
511
|
</div>
|
512
|
</div>
|
513
|
</xsl:template>
|
514
|
|
515
|
<xsl:template name="datasetpublisher">
|
516
|
<xsl:for-each select="publisher">
|
517
|
<div class="control-group">
|
518
|
<label class="control-label"><xsl:text>Publisher</xsl:text></label>
|
519
|
<div class="controls">
|
520
|
<xsl:call-template name="party">
|
521
|
<xsl:with-param name="partyfirstColStyle" select="$firstColStyle"/>
|
522
|
</xsl:call-template>
|
523
|
</div>
|
524
|
</div>
|
525
|
</xsl:for-each>
|
526
|
</xsl:template>
|
527
|
|
528
|
<xsl:template name="datasetpubplace">
|
529
|
<xsl:for-each select="pubPlace">
|
530
|
<div class="control-group">
|
531
|
<label class="control-label">Publish Place</label>
|
532
|
<div class="controls">
|
533
|
<xsl:value-of select="."/>
|
534
|
</div>
|
535
|
</div>
|
536
|
</xsl:for-each>
|
537
|
</xsl:template>
|
538
|
|
539
|
<xsl:template name="datasetmethod">
|
540
|
<xsl:for-each select=".">
|
541
|
<xsl:call-template name="method">
|
542
|
<xsl:with-param name="methodfirstColStyle" select="$firstColStyle"/>
|
543
|
</xsl:call-template>
|
544
|
</xsl:for-each>
|
545
|
</xsl:template>
|
546
|
|
547
|
<xsl:template name="datasetproject">
|
548
|
<h4><xsl:text>Parent Project Information</xsl:text></h4>
|
549
|
<xsl:for-each select="project">
|
550
|
<div class="row-fluid">
|
551
|
<xsl:call-template name="project">
|
552
|
<xsl:with-param name="projectfirstColStyle" select="$firstColStyle"/>
|
553
|
</xsl:call-template>
|
554
|
</div>
|
555
|
</xsl:for-each>
|
556
|
</xsl:template>
|
557
|
|
558
|
<xsl:template name="datasetaccess">
|
559
|
<xsl:for-each select="access">
|
560
|
<div class="row-fluid">
|
561
|
<xsl:call-template name="access">
|
562
|
<xsl:with-param name="accessfirstColStyle" select="$firstColStyle"/>
|
563
|
<xsl:with-param name="accesssubHeaderStyle" select="$subHeaderStyle"/>
|
564
|
</xsl:call-template>
|
565
|
</div>
|
566
|
</xsl:for-each>
|
567
|
</xsl:template>
|
568
|
|
569
|
<xsl:template name="datasetentity">
|
570
|
<xsl:if test="dataTable or spatialRaster or spatialVector or storedProcedures or view or otherEntity">
|
571
|
<h4>
|
572
|
<xsl:text>Data Table, Image, and Other Data Details</xsl:text>
|
573
|
</h4>
|
574
|
</xsl:if>
|
575
|
|
576
|
<xsl:call-template name="xml" />
|
577
|
|
578
|
<xsl:choose>
|
579
|
<xsl:when test="$displaymodule!='printall'">
|
580
|
<xsl:for-each select="dataTable">
|
581
|
<xsl:call-template name="entityurl">
|
582
|
<xsl:with-param name="type">dataTable</xsl:with-param>
|
583
|
<xsl:with-param name="showtype">Data Table</xsl:with-param>
|
584
|
<xsl:with-param name="index" select="position()" />
|
585
|
</xsl:call-template>
|
586
|
</xsl:for-each>
|
587
|
<xsl:for-each select="spatialRaster">
|
588
|
<xsl:call-template name="entityurl">
|
589
|
<xsl:with-param name="type">spatialRaster</xsl:with-param>
|
590
|
<xsl:with-param name="showtype">Spatial Raster</xsl:with-param>
|
591
|
<xsl:with-param name="index" select="position()" />
|
592
|
</xsl:call-template>
|
593
|
</xsl:for-each>
|
594
|
<xsl:for-each select="spatialVector">
|
595
|
<xsl:call-template name="entityurl">
|
596
|
<xsl:with-param name="type">spatialVector</xsl:with-param>
|
597
|
<xsl:with-param name="showtype">Spatial Vector</xsl:with-param>
|
598
|
<xsl:with-param name="index" select="position()" />
|
599
|
</xsl:call-template>
|
600
|
</xsl:for-each>
|
601
|
<xsl:for-each select="storedProcedure">
|
602
|
<xsl:call-template name="entityurl">
|
603
|
<xsl:with-param name="type">storedProcedure</xsl:with-param>
|
604
|
<xsl:with-param name="showtype">Stored Procedure</xsl:with-param>
|
605
|
<xsl:with-param name="index" select="position()" />
|
606
|
</xsl:call-template>
|
607
|
</xsl:for-each>
|
608
|
<xsl:for-each select="view">
|
609
|
<xsl:call-template name="entityurl">
|
610
|
<xsl:with-param name="type">view</xsl:with-param>
|
611
|
<xsl:with-param name="showtype">View</xsl:with-param>
|
612
|
<xsl:with-param name="index" select="position()" />
|
613
|
</xsl:call-template>
|
614
|
</xsl:for-each>
|
615
|
<xsl:for-each select="otherEntity">
|
616
|
<xsl:call-template name="entityurl">
|
617
|
<xsl:with-param name="type">otherEntity</xsl:with-param>
|
618
|
<xsl:with-param name="showtype">Other Data</xsl:with-param>
|
619
|
<xsl:with-param name="index" select="position()" />
|
620
|
</xsl:call-template>
|
621
|
</xsl:for-each>
|
622
|
</xsl:when>
|
623
|
<xsl:otherwise>
|
624
|
<xsl:for-each select="dataTable">
|
625
|
<xsl:variable name="currentNode" select="position()" />
|
626
|
<xsl:for-each select="../.">
|
627
|
<div class="control-group entity">
|
628
|
<div class="controls controls-well entitydetails">
|
629
|
<label class="control-label">
|
630
|
<xsl:text>Data Table</xsl:text>
|
631
|
</label>
|
632
|
<xsl:call-template name="chooseentity">
|
633
|
<xsl:with-param name="entitytype">dataTable</xsl:with-param>
|
634
|
<xsl:with-param name="entityindex" select="$currentNode" />
|
635
|
</xsl:call-template>
|
636
|
</div>
|
637
|
</div>
|
638
|
</xsl:for-each>
|
639
|
</xsl:for-each>
|
640
|
<xsl:for-each select="spatialRaster">
|
641
|
<xsl:variable name="currentNode" select="position()" />
|
642
|
<xsl:for-each select="../.">
|
643
|
<div class="control-group entity">
|
644
|
<div class="controls controls-well entitydetails">
|
645
|
<label class="control-label">
|
646
|
<xsl:text>Spatial Raster</xsl:text>
|
647
|
</label>
|
648
|
<xsl:call-template name="chooseentity">
|
649
|
<xsl:with-param name="entitytype">spatialRaster</xsl:with-param>
|
650
|
<xsl:with-param name="entityindex" select="$currentNode" />
|
651
|
</xsl:call-template>
|
652
|
</div>
|
653
|
</div>
|
654
|
</xsl:for-each>
|
655
|
</xsl:for-each>
|
656
|
<xsl:for-each select="spatialVector">
|
657
|
<xsl:variable name="currentNode" select="position()" />
|
658
|
<xsl:for-each select="../.">
|
659
|
<div class="control-group entity">
|
660
|
<div class="controls controls-well entitydetails">
|
661
|
<label class="control-label">
|
662
|
<xsl:text>Spatial Vector</xsl:text>
|
663
|
</label>
|
664
|
<xsl:call-template name="chooseentity">
|
665
|
<xsl:with-param name="entitytype">spatialVector</xsl:with-param>
|
666
|
<xsl:with-param name="entityindex" select="$currentNode" />
|
667
|
</xsl:call-template>
|
668
|
</div>
|
669
|
</div>
|
670
|
</xsl:for-each>
|
671
|
</xsl:for-each>
|
672
|
<xsl:for-each select="storedProcedure">
|
673
|
<xsl:variable name="currentNode" select="position()" />
|
674
|
<xsl:for-each select="../.">
|
675
|
<div class="control-group entity">
|
676
|
<div class="controls controls-well entitydetails">
|
677
|
<label class="control-label">
|
678
|
<xsl:text>Stored Procedure</xsl:text>
|
679
|
</label>
|
680
|
<xsl:call-template name="chooseentity">
|
681
|
<xsl:with-param name="entitytype">storedProcedure</xsl:with-param>
|
682
|
<xsl:with-param name="entityindex" select="$currentNode" />
|
683
|
</xsl:call-template>
|
684
|
</div>
|
685
|
</div>
|
686
|
</xsl:for-each>
|
687
|
</xsl:for-each>
|
688
|
<xsl:for-each select="view">
|
689
|
<xsl:variable name="currentNode" select="position()" />
|
690
|
<xsl:for-each select="../.">
|
691
|
<div class="control-group entity">
|
692
|
<div class="controls controls-well entitydetails">
|
693
|
<label class="control-label">
|
694
|
<xsl:text>View</xsl:text>
|
695
|
</label>
|
696
|
<xsl:call-template name="chooseentity">
|
697
|
<xsl:with-param name="entitytype">view</xsl:with-param>
|
698
|
<xsl:with-param name="entityindex" select="$currentNode" />
|
699
|
</xsl:call-template>
|
700
|
</div>
|
701
|
</div>
|
702
|
</xsl:for-each>
|
703
|
</xsl:for-each>
|
704
|
<xsl:for-each select="otherEntity">
|
705
|
<xsl:variable name="currentNode" select="position()" />
|
706
|
<xsl:for-each select="../.">
|
707
|
<div class="control-group entity">
|
708
|
<div class="controls controls-well entitydetails">
|
709
|
<label class="control-label">
|
710
|
<xsl:text>Other Entity</xsl:text>
|
711
|
</label>
|
712
|
<xsl:call-template name="chooseentity">
|
713
|
<xsl:with-param name="entitytype">otherEntity</xsl:with-param>
|
714
|
<xsl:with-param name="entityindex" select="$currentNode" />
|
715
|
</xsl:call-template>
|
716
|
</div>
|
717
|
</div>
|
718
|
</xsl:for-each>
|
719
|
</xsl:for-each>
|
720
|
</xsl:otherwise>
|
721
|
</xsl:choose>
|
722
|
</xsl:template>
|
723
|
|
724
|
<xsl:template name="entityurl">
|
725
|
<xsl:param name="showtype" />
|
726
|
<xsl:param name="type" />
|
727
|
<xsl:param name="index" />
|
728
|
<xsl:choose>
|
729
|
<xsl:when test="references!=''">
|
730
|
<xsl:variable name="ref_id" select="references" />
|
731
|
<xsl:variable name="references" select="$ids[@id=$ref_id]" />
|
732
|
<xsl:for-each select="$references">
|
733
|
<div class="control-group">
|
734
|
<label class="control-label">
|
735
|
View Metadata
|
736
|
</label>
|
737
|
<div class="controls controls-well">
|
738
|
<a>
|
739
|
<xsl:attribute name="href">
|
740
|
<xsl:value-of select="$tripleURI" /><xsl:value-of select="$docid" />&displaymodule=entity&entitytype=<xsl:value-of select="$type"/>&entityindex=<xsl:value-of select="$index"/>
|
741
|
</xsl:attribute>
|
742
|
<xsl:value-of select="./physical/objectName"/>
|
743
|
</a>
|
744
|
</div>
|
745
|
</div>
|
746
|
</xsl:for-each>
|
747
|
</xsl:when>
|
748
|
<xsl:otherwise>
|
749
|
<div class="control-group">
|
750
|
<label class="control-label">
|
751
|
<xsl:value-of select="$showtype"/>
|
752
|
</label>
|
753
|
<div class="controls controls-well">
|
754
|
<xsl:value-of select="./entityName"/>
|
755
|
(<a>
|
756
|
<xsl:attribute name="href">
|
757
|
<xsl:value-of select="$tripleURI"/><xsl:value-of select="$docid"/>&displaymodule=entity&entitytype=<xsl:value-of select="$type"/>&entityindex=<xsl:value-of select="$index"/></xsl:attribute>
|
758
|
View Metadata</a>
|
759
|
<xsl:text> </xsl:text>
|
760
|
<xsl:choose>
|
761
|
<xsl:when test="./physical/distribution/online/url">
|
762
|
|
|
763
|
<xsl:variable name="URL" select="./physical/distribution/online/url"/>
|
764
|
<a>
|
765
|
<xsl:choose>
|
766
|
<xsl:when test="starts-with($URL,'ecogrid')">
|
767
|
<xsl:variable name="URL1" select="substring-after($URL, 'ecogrid://')"/>
|
768
|
<xsl:variable name="dataDocID" select="substring-after($URL1, '/')"/>
|
769
|
<xsl:attribute name="href">
|
770
|
<xsl:value-of select="$tripleURI"/><xsl:value-of select="$dataDocID"/>
|
771
|
</xsl:attribute>
|
772
|
</xsl:when>
|
773
|
<xsl:otherwise>
|
774
|
<xsl:attribute name="href"><xsl:value-of select="$URL"/></xsl:attribute>
|
775
|
</xsl:otherwise>
|
776
|
</xsl:choose>
|
777
|
<xsl:attribute name="target">_blank</xsl:attribute>
|
778
|
Download File <i class="icon-download" alt="download"></i>
|
779
|
</a>
|
780
|
</xsl:when>
|
781
|
</xsl:choose>)
|
782
|
</div>
|
783
|
</div>
|
784
|
</xsl:otherwise>
|
785
|
</xsl:choose>
|
786
|
</xsl:template>
|
787
|
|
788
|
<xsl:template match="text()" mode="dataset" />
|
789
|
<xsl:template match="text()" mode="resource" />
|
790
|
|
791
|
</xsl:stylesheet>
|