-
Notifications
You must be signed in to change notification settings - Fork 1
/
EMLDialog.html
executable file
·188 lines (167 loc) · 7.1 KB
/
EMLDialog.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
<!DOCTYPE html>
<html>
<head>
<?!= include('Header'); ?>
<?!= include('EMLDialogCSS'); ?>
<?!= include('EMLDialogJS'); ?>
</head>
<body>
<? var data = getEMLData(); ?>
<div class="eml">
<div class="inline form-group">
<label for="title">Title*</label>
<input type="text" id="title" class="form-control-plaintext" value="<?= data['title']; ?>">
</div>
<div class="alternate-identifiers">
<div class="form-group">
<label>Alternate Identifiers</label>
<button id="add-alternate-identifier">Add</button>
<div class="identifiers form-group"></div>
</div>
</div>
<div class="creators margin-bottom">
<h6>Creators:*</h6>
<p>The first author will be the contact author</p>
<div>
<div class="inline form-group">
<label for="creator-given-name">Given name</label>
<input type="text" id="creator-given-name"/>
</div>
<div class="inline form-group">
<label for="creator-surname">Surname</label>
<input type="text" id="creator-surname"/>
</div>
</div>
<div>
<div class="inline form-group">
<label for="creator-email">Email</label>
<input type="text" id="creator-email"/>
</div>
<div class="inline form-group">
<label for="creator-organization-name">Organization name</label>
<input type="text" id="creator-organization-name"/>
</div>
</div>
<button id="add-creator">Add creator</button>
</div>
<div class="creators-list">
<div class="block form-group">
<select id="creators" size="5" class="custom-select" multiple>
<? if( data['creators'].length > 0 ) { ?>
<? for(var i = 0; i < data['creators'].length; i++ ) {
var creator = data['creators'][i];
var value = creator['givenName'] + "|" + creator['surname'] + "|" + creator['org'] + "|" + creator['email'];
var text = creator['givenName'] + " " + creator['surname'] + " - " + creator['org'] + "(" + creator['email'] + ")";
?>
<option value="<?= value ?>"><?= text ?></option>
<? } ?>
<? } ?>
</select>
<button id="remove-creator" class="margin-top">Remove creator</button>
</div>
</div>
<div class="form-group">
<h6>Data Prodiver:*</h6>
<div class="inline form-group">
<label for="given-name">Given name</label>
<input type="text" id="given-name" value="<?= data['given-name'] ?>">
</div>
<div class="inline form-group">
<label for="surname">Surname</label>
<input type="text" id="surname" value="<?= data['surname'] ?>">
</div>
<div class="inline form-group">
<label for="email">Email</label>
<input type="text" id="email" value="<?= data['email'] ?>">
</div>
</div>
<div class="form-group">
<div class="inline form-group">
<label for="organization-name">Organization name*</label>
<input type="text" id="organization-name" value="<?= data['organization-name'] ?>">
</div>
<!-- <div class="inline form-group">
<label for="organization-code">Organization code</label>
<input type="text" id="organization-code" value="<?= data['organization-code'] ?>">
</div> -->
<!-- <div class="inline form-group">
<label for="dataset-name">Dataset name</label>
<input type="text" id="dataset-name" value="<?= data['dataset-name'] ?>">
</div> -->
</div>
<div class="form-group">
<label for="abstract">Abstract (description of the dataset)*</label>
<textarea id="abstract" rows="5" class="form-control"><?= data['abstract'] ?></textarea>
</div>
<div class="form-group">
<!-- <div class="inline form-group">
<label for="dataset-id">Dataset ID</label>
<input type="text" id="dataset-id" value="<?= data['dataset-id'] ?>">
</div> -->
<div class="inline form-group">
<label for="keywords">Keywords (separared by ;)</label>
<input type="text" id="keywords" value="<?= data['keywords'] ?>">
</div>
</div>
<div class="form-group">
<label for="additional-info">Additional information</label>
<textarea id="additional-info" rows="5" class="form-control"><?= data['additional-info'] ?></textarea>
</div>
<!-- <div class="form-group">
<label for="taxonomic-coverage">General taxonomic coverage</label>
<textarea id="taxonomic-coverage" rows="5" class="form-control"><?= data['taxonomic-coverage'] ?></textarea>
</div> -->
<!-- <div>
<input type="checkbox" id="auto-taxonomic-coverage" <? if(data['auto-taxonomic-coverage']) { ?> checked <? } ?>>
<label for="auto-taxonomic-coverage">Auto generate taxonomic coverage from field:
<div class="inline form-group">
<? var fields = getSpredsheetFields(); ?>
<select id="taxonomic-field">
<? for(var i = 0; i < fields.length; i++ ) { ?>
<option value="<?= fields[i].index ?>" <? if(data['taxonomic-field'] == fields[i].term) { ?> selected <? } ?>><?= fields[i].term ?></option>
<? } ?>
</select>
</div>
</label>
</div> -->
<!-- <div class="form-group">
<label for="geographic-coverage">General geographic coverage</label>
<textarea id="geographic-coverage" rows="5" class="form-control"><?= data['geographic-coverage'] ?></textarea>
</div> -->
<!-- <div>
<label for="auto-geographic-coverage">
<input type="checkbox" id="auto-geographic-coverage" <? if (data['auto-geographic-coverage']) { ?> checked <? } ?>>
Auto generate geographic coverage from dwc:decimalLongitude and dwc:decimalLatitude fields?
</label>
</div> -->
<!-- <div class="form-group">
<label for="purpose">Purpose</label>
<textarea id="purpose" rows="5" class="form-control"><?= data['purpose'] ?></textarea>
</div> -->
<div class="form-group">
<label for="rights">Intellectual rights</label>
<textarea id="rights" rows="5" class="form-control"><?= data['rights'] ?></textarea>
</div>
<div class="block form-group">
<label for="lang">Metadata language</label>
<select id="lang">
<option value=""></option>
<option value="en" <? if(data['lang'] == 'en') { ?> selected <? } ?>>en - English</option>
<option value="pt" <? if(data['lang'] == 'pt') { ?> selected <? } ?>>pt - Portuguese</option>
<option value="es" <? if(data['lang'] == 'es') { ?> selected <? } ?>>es - Spanish</option>
</select>
</div>
</div>
<div class="eml-content">
<div>
<input type="checkbox" id="enable-manual-eml" <? if (data['enable-manual-eml']) { ?> checked <? } ?>>
<label for="enable-manual-eml">Manually enter EML content</label>
</div>
<div class="form-group eml-editor">
<label for="manual-eml">Enter your EML content below:</label>
<textarea id="manual-eml" rows="30" class="form-control"><?= data['manual-eml'] ?></textarea>
</div>
</div>
<button class="action" id="save-eml">Save</button>
</body>
</html>