booklet.ftl 2.19 KB
Newer Older
1
2
3
4
5
6
7
8
<#macro isPublished published what>
	<#if published>

	<#else>
		<div class="alert not-published"><b>Note:</b> This ${what} is not published.</div><#lt>
	</#if>
</#macro>

9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30

<#assign vocabprinted = { "dummy":true } />
<#macro printVocabulary vocabulary>
	<#compress>
		**Note:** This descriptor uses the **${vocabulary.title}** controlled vocabulary
		<#if vocabulary.publisher??>
		published by **${vocabulary.publisher}**
		<#else>
		maintained by **${vocabulary.owner.name}**
		</#if>.
	</#compress>



	<#if vocabprinted[vocabulary.uuid]??>
	<#else>
		${vocabulary.description!}<#lt>
		<#assign vocabprinted = vocabprinted + { vocabulary.uuid:true } />
	</#if>

</#macro>

31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<#macro printDescriptor descriptor>
		# ${descriptor.title} <#if descriptor.uom??>[${descriptor.uom}]</#if><#lt>

		<@isPublished published=descriptor.published what="descriptor" />

		<#if descriptor.description??>
			${descriptor.description}<#lt>
		<#else>
			> No description.<#lt>
		</#if>


		<#list descriptor.terms>
			<#compress>
				|Code|Term|Description|
				|---|---|---|
				<#items as term>
					|**${term.code}**|${term.title}|${term.description!}|
				</#items>
			</#compress>
		</#list>

		<#if descriptor.vocabulary??>
54
			<@printVocabulary vocabulary=descriptor.vocabulary />
55
56
57
		</#if>
</#macro>

58
59
60
61
62
63
64
65
66
67
68
<div class="documenttitle">
	${descriptorList.title} <#lt>
<div><small>
	${descriptorList.versionTag}<br />
	<#if descriptorList.publisher??>
	**${descriptorList.publisher}**  <#lt>
	<#else>
	${descriptorList.owner.name}  <#lt>
	</#if>
</small></div>
</div>
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98

${descriptorList.description!}

<@isPublished published=descriptorList.published what="descriptor list" />


Version: ${descriptorList.versionTag}  <#lt>
<#if descriptorList.publisher??>
Published by: **${descriptorList.publisher}**  <#lt>
<#else>
Maintained by: ${descriptorList.owner.name}  <#lt>
</#if>
Last modified: ${descriptorList.lastModifiedDate?date}  <#lt>
Date registered: ${descriptorList.createdDate?date}  <#lt>
Record: ${descriptorList.uuid} v${descriptorList.version}  <#lt>


<#list descriptorList.descriptors>

	<#items as descriptor>

		<@printDescriptor descriptor=descriptor />

	</#items>

<#else>

> The descriptor list does not declare any descriptors.

</#list>