1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
2 | <CollectionConfig xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
---|
3 |
|
---|
4 | <metadataList>
|
---|
5 | <metadata lang="en" name="creator"></metadata>
|
---|
6 | <metadata lang="en" name="maintainer"></metadata>
|
---|
7 | <metadata lang="en" name="public">true</metadata>
|
---|
8 | </metadataList>
|
---|
9 | <displayItemList>
|
---|
10 | <displayItem assigned="true" lang="en" name="name">Pei-Jones-Flat</displayItem>
|
---|
11 | </displayItemList>
|
---|
12 | <search type="mgpp">
|
---|
13 | <level name="document">
|
---|
14 | <displayItem lang="en" name="name">document</displayItem>
|
---|
15 | </level>
|
---|
16 | <level name="section">
|
---|
17 | <displayItem lang="en" name="name">section</displayItem>
|
---|
18 | </level>
|
---|
19 | <defaultLevel name="document"/>
|
---|
20 | <index name="text">
|
---|
21 | <displayItem lang="en" name="name">text</displayItem>
|
---|
22 | </index>
|
---|
23 | <index name="Title">
|
---|
24 | <displayItem lang="en" name="name">titles</displayItem>
|
---|
25 | </index>
|
---|
26 | <index name="Source">
|
---|
27 | <displayItem lang="en" name="name">filenames</displayItem>
|
---|
28 | </index>
|
---|
29 | <index name="Plugin"/>
|
---|
30 | <index name="gsimg.photoNote">
|
---|
31 | <displayItem lang="en" name="name">photo annotations</displayItem>
|
---|
32 | </index>
|
---|
33 | <index name="gstext.tags">
|
---|
34 | <displayItem lang="en" name="name">text annotations (tags)</displayItem>
|
---|
35 | </index>
|
---|
36 | <index name="gstext.text">
|
---|
37 | <displayItem lang="en" name="name">text annotations (text)</displayItem>
|
---|
38 | </index>
|
---|
39 | <index name="gstext.user">
|
---|
40 | <displayItem lang="en" name="name">text annotations (user)</displayItem>
|
---|
41 | </index>
|
---|
42 | <index name="SourceFile"/>
|
---|
43 | <defaultIndex name="text"/>
|
---|
44 | <indexOption>
|
---|
45 | <option name="accentfold"/>
|
---|
46 | <option name="casefold"/>
|
---|
47 | <option name="stem"/>
|
---|
48 | </indexOption>
|
---|
49 | <searchType name="plain"/>
|
---|
50 | <searchType name="simpleform"/>
|
---|
51 | <searchType name="advancedform"/>
|
---|
52 | <format>
|
---|
53 | <gsf:template match="documentNode">
|
---|
54 | <td valign="top">
|
---|
55 | <gsf:link type="document">
|
---|
56 | <gsf:icon type="document"/>
|
---|
57 | </gsf:link>
|
---|
58 | </td>
|
---|
59 | <td>
|
---|
60 | <gsf:switch>
|
---|
61 | <gsf:metadata name="Title" select="ancestors" separator=": "/>
|
---|
62 | <gsf:when test="exists"><gsf:metadata name="Title" select="ancestors" separator=": "/>:</gsf:when>
|
---|
63 | </gsf:switch>
|
---|
64 | <gsf:link type="document">
|
---|
65 | <gsf:metadata name="Title"/>
|
---|
66 | </gsf:link>
|
---|
67 | </td>
|
---|
68 | </gsf:template>
|
---|
69 | </format>
|
---|
70 | </search>
|
---|
71 | <infodb type="gdbm"/>
|
---|
72 | <import>
|
---|
73 | <pluginList>
|
---|
74 | <plugin name="ZIPPlugin"/>
|
---|
75 | <plugin name="GreenstoneXMLPlugin"/>
|
---|
76 | <plugin name="TextPlugin">
|
---|
77 | <option name="-extract_language"/>
|
---|
78 | <option name="-default_language" value="undefined"/>
|
---|
79 | </plugin>
|
---|
80 | <plugin name="HTMLPlugin">
|
---|
81 | <option name="-process_exp" value="(timeglider.*)(?i)(\.html?)$"/>
|
---|
82 | <option name="-block_exp" value="(timeglider.*)(?i)(\.jpe?g|\.png|\.gif)$"/>
|
---|
83 | <option name="-keep_head"/>
|
---|
84 | <option name="-extract_language"/>
|
---|
85 | <option name="-default_language" value="undefined"/>
|
---|
86 | </plugin>
|
---|
87 | <plugin name="EmailPlugin"/>
|
---|
88 | <plugin name="PDFPlugin"/>
|
---|
89 | <plugin name="RTFPlugin"/>
|
---|
90 | <plugin name="WordPlugin"/>
|
---|
91 | <plugin name="PostScriptPlugin"/>
|
---|
92 | <plugin name="PowerPointPlugin"/>
|
---|
93 | <plugin name="ExcelPlugin"/>
|
---|
94 | <plugin name="PagedImagePlugin"/>
|
---|
95 | <plugin name="ImagePlugin"/>
|
---|
96 | <plugin name="ISISPlugin"/>
|
---|
97 | <plugin name="NulPlugin"/>
|
---|
98 | <plugin name="OAIPlugin"/>
|
---|
99 | <plugin name="HTMLImagePlugin"/>
|
---|
100 | <plugin name="MetadataXMLPlugin"/>
|
---|
101 | <plugin name="ArchivesInfPlugin"/>
|
---|
102 | <plugin name="DirectoryPlugin"/>
|
---|
103 | </pluginList>
|
---|
104 | </import>
|
---|
105 | <browse>
|
---|
106 | <classifier name="List">
|
---|
107 | <option name="-metadata" value="dc.Title;Title"/>
|
---|
108 | <option name="-partition_type_within_level" value="approximate_size"/>
|
---|
109 | <option name="-bookshelf_type" value="never"/>
|
---|
110 | </classifier>
|
---|
111 | <classifier name="AZCompactList">
|
---|
112 | <option name="-metadata" value="Source"/>
|
---|
113 | <option name="-removesuffix" value="(?i)\\..*"/>
|
---|
114 | <option name="-buttonname" value="Source"/>
|
---|
115 | </classifier>
|
---|
116 | <format>
|
---|
117 | <gsf:template match="documentNode">
|
---|
118 | <td valign="top">
|
---|
119 | <gsf:link type="document">
|
---|
120 | <gsf:icon type="document"/>
|
---|
121 | </gsf:link>
|
---|
122 | </td>
|
---|
123 | <td valign="top">
|
---|
124 | <gsf:link type="source">
|
---|
125 | <gsf:choose-metadata>
|
---|
126 | <gsf:metadata name="thumbicon"/>
|
---|
127 | <gsf:metadata name="srcicon"/>
|
---|
128 | </gsf:choose-metadata>
|
---|
129 | </gsf:link>
|
---|
130 | </td>
|
---|
131 | <td valign="top">
|
---|
132 | <gsf:link type="document">
|
---|
133 | <gsf:choose-metadata>
|
---|
134 | <gsf:metadata name="dc.Title"/>
|
---|
135 | <gsf:metadata name="exp.Title"/>
|
---|
136 | <gsf:metadata name="Title"/>
|
---|
137 | <gsf:default>Untitled</gsf:default>
|
---|
138 | </gsf:choose-metadata>
|
---|
139 | </gsf:link>
|
---|
140 | <gsf:switch>
|
---|
141 | <gsf:metadata name="Source"/>
|
---|
142 | <gsf:when test="exists">
|
---|
143 | <br/>
|
---|
144 | <i>(<gsf:metadata name="Source"/>)</i>
|
---|
145 | </gsf:when>
|
---|
146 | </gsf:switch>
|
---|
147 | </td>
|
---|
148 | </gsf:template>
|
---|
149 | <gsf:template match="classifierNode">
|
---|
150 | <td valign="top">
|
---|
151 | <gsf:link type="classifier">
|
---|
152 | <gsf:icon type="classifier"/>
|
---|
153 | </gsf:link>
|
---|
154 | </td>
|
---|
155 | <td valign="top">
|
---|
156 | <gsf:metadata name="srclink"/>
|
---|
157 | <gsf:choose-metadata>
|
---|
158 | <gsf:metadata name="thumbicon"/>
|
---|
159 | <gsf:metadata name="srcicon"/>
|
---|
160 | </gsf:choose-metadata>
|
---|
161 | <gsf:metadata name="/srclink"/>
|
---|
162 | </td>
|
---|
163 | <td valign="top">
|
---|
164 | <gsf:choose-metadata>
|
---|
165 | <gsf:metadata name="dc.Title"/>
|
---|
166 | <gsf:metadata name="exp.Title"/>
|
---|
167 | <gsf:metadata name="Title"/>
|
---|
168 | <gsf:default>Untitled</gsf:default>
|
---|
169 | </gsf:choose-metadata>
|
---|
170 | <gsf:switch>
|
---|
171 | <gsf:metadata name="Source"/>
|
---|
172 | <gsf:when test="exists">
|
---|
173 | <br/>
|
---|
174 | <i>(<gsf:metadata name="Source"/>)</i>
|
---|
175 | </gsf:when>
|
---|
176 | </gsf:switch>
|
---|
177 | </td>
|
---|
178 | </gsf:template>
|
---|
179 | <gsf:template match="classifierNode" mode="horizontal">
|
---|
180 | <gsf:link type="horizontal">
|
---|
181 | <gsf:metadata name="Title"/>
|
---|
182 | </gsf:link>
|
---|
183 | </gsf:template>
|
---|
184 | </format>
|
---|
185 | </browse>
|
---|
186 | <display>
|
---|
187 | <format>
|
---|
188 | <gsf:option name="sideBar" value="false"/>
|
---|
189 | <xsl:template name="additionalHeaderContent">
|
---|
190 | <!--
|
---|
191 | <link rel="stylesheet" href="http://twitter.github.com/bootstrap/1.4.0/bootstrap.min.css"/>
|
---|
192 | <link rel="stylesheet" href="http://blueimp.github.com/Bootstrap-Image-Gallery/bootstrap-image-gallery.min.css"/> --><!--[if lt IE 7]><link rel="stylesheet" href="http://blueimp.github.com/Bootstrap-Image-Gallery/bootstrap-ie6.min.css"><![endif]--><!--
|
---|
193 | <link rel="stylesheet" href="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.fileupload-ui.css"/>
|
---|
194 |
|
---|
195 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.fileupload.js">
|
---|
196 | <xsl:text> </xsl:text>
|
---|
197 | </script>
|
---|
198 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.fileupload-ui.js">
|
---|
199 | <xsl:text> </xsl:text>
|
---|
200 | </script>
|
---|
201 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.iframe-transport.js">
|
---|
202 | <xsl:text> </xsl:text>
|
---|
203 | </script>
|
---|
204 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/application.js">
|
---|
205 | <xsl:text> </xsl:text>
|
---|
206 | </script>
|
---|
207 |
|
---|
208 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/tmpl.min.js"><xsl:text> </xsl:text></script>
|
---|
209 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/load-image.min.js"><xsl:text> </xsl:text></script>
|
---|
210 | --><!-- jQuery must be included before Annotator --><!-- <script src="sites/localsite/collect/peijones/js/annotator/lib/vendor/jquery.js">--><!--<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"><xsl:text> </xsl:text></script>--><!-- If you're sure your users will only be using browsers modern
|
---|
211 | enough to have their own JSON.parse and JSON.stringify
|
---|
212 | implementations you can skip this --> <xsl:if test="not(/page/pageRequest/paramList/param[@name ='p.docEdit'])">
|
---|
213 | <script src="sites/localsite/collect/peijones/js/annotator/lib/vendor/json2.js">
|
---|
214 | <xsl:text> </xsl:text> </script>
|
---|
215 | <script src="sites/localsite/collect/peijones/js/annotator/pkg/annotator-full.min.js">
|
---|
216 | <xsl:text> </xsl:text> </script>
|
---|
217 | <link href="sites/localsite/collect/peijones/js/annotator/pkg/annotator.min.css" rel="stylesheet" type="text/css"/>
|
---|
218 | </xsl:if>
|
---|
219 | <!-- The main Annotator script --><!--<script src="sites/localsite/collect/peijones/js/annotator/pkg/annotator.min.js"><xsl:text> </xsl:text></script> --><!-- Annotator's styling and images --><!-- The following plugins are entirely optional --><!-- The Store plugin. Saves annotations to a remote backend --><!-- <script src="sites/localsite/collect/peijones/js/annotator/pkg/annotator.store.min.js"><xsl:text> </xsl:text></script> --><!-- The Auth plugin. Allows users of Annotator to authenticate themselves
|
---|
220 | to the remote backend --><!--<script src="sites/localsite/collect/peijones/js/annotator/pkg/annotator.auth.min.js"><xsl:text> </xsl:text></script> --><!-- The Permissions plugin. See who created which annotation and create
|
---|
221 | annotations as a specified user --><!--<script src="sites/localsite/collect/peijones/js/annotator/pkg/annotator.permissions.min.js"><xsl:text> </xsl:text></script> --><!-- The Tags plugin. Edit and display tag keywords on annotations --><!--<script src="sites/localsite/collect/peijones/js/annotator/pkg/annotator.tags.min.js"><xsl:text> </xsl:text></script> --><!-- The Markdown plugin. Treat annotation text as Markdown --><!-- <script src="sites/localsite/collect/peijones/js/annotator/lib/vendor/showdown.js"><xsl:text> </xsl:text></script> --><!-- <script src="sites/localsite/collect/peijones/js/annotator/pkg/annotator.markdown.min.js"><xsl:text> </xsl:text></script> --><!-- Photo note scripts --> <xsl:if test="not(/page/pageRequest/paramList/param[@name ='p.docEdit'])">
|
---|
222 | <script src="sites/localsite/collect/peijones/js/documentmaker/BrowserDetect.js" type="text/javascript">
|
---|
223 | <xsl:text> </xsl:text> </script>
|
---|
224 | <script src="sites/localsite/collect/peijones/js/documentmaker/PhotoNotes-1.5.js" type="text/javascript">
|
---|
225 | <xsl:text> </xsl:text> </script>
|
---|
226 | <link href="sites/localsite/collect/peijones/style/PhotoNotes-1.5.css" rel="stylesheet" type="text/css"/>
|
---|
227 | </xsl:if>
|
---|
228 | <!-- Zoom scripts --><!--<script src="interfaces/{$interface_name}/js/jquery-1.4.2.js" type="text/javascript"><xsl:text> </xsl:text></script>--> <script src="sites/localsite/collect/peijones/js/documentmaker/zoomer.jquery.js" type="text/javascript">
|
---|
229 | <xsl:text> </xsl:text> </script>
|
---|
230 | <link href="sites/localsite/collect/peijones/style/style.css" rel="stylesheet" type="text/css"/>
|
---|
231 | <script type="text/javascript">
|
---|
232 | <xsl:text disable-output-escaping="yes">_zoomEnabled = true;
|
---|
233 |
|
---|
234 | function readyImagesForZoom()
|
---|
235 | {
|
---|
236 | var noZoom = document.getElementById("noZoomImage");
|
---|
237 | var wrap = document.getElementById("wrap");
|
---|
238 | if(!noZoom || !wrap)
|
---|
239 | {
|
---|
240 | return;
|
---|
241 | }
|
---|
242 |
|
---|
243 | var smallImageDiv = document.getElementById("small");
|
---|
244 | var smallImage = smallImageDiv.getElementsByTagName("img")[0];
|
---|
245 | smallImageDiv.style.width = smallImageWidth + "px";
|
---|
246 | smallImageDiv.style.height = smallImageHeight + "px";
|
---|
247 | var multiplier = largeImageHeight / smallImageHeight;
|
---|
248 |
|
---|
249 | $("#wrap").anythingZoomer({
|
---|
250 | expansionSize:50,
|
---|
251 | speedMultiplier:multiplier
|
---|
252 | });
|
---|
253 |
|
---|
254 | noZoom.onclick = addZoom;
|
---|
255 | document.getElementById("overlay").onclick = removeZoom;
|
---|
256 |
|
---|
257 | removeZoom();
|
---|
258 | }
|
---|
259 | function addZoom()
|
---|
260 | {
|
---|
261 | if(!_zoomEnabled)
|
---|
262 | {
|
---|
263 | return;
|
---|
264 | }
|
---|
265 |
|
---|
266 | var wrapper = document.getElementById("wrap");
|
---|
267 | var noZoom = document.getElementById("noZoom");
|
---|
268 |
|
---|
269 | if(!noZoom || !wrapper)
|
---|
270 | {
|
---|
271 | return;
|
---|
272 | }
|
---|
273 |
|
---|
274 | noZoom.style.display = "none";
|
---|
275 | wrapper.style.display = "block";
|
---|
276 | var option = document.getElementById("zoomOption");
|
---|
277 | if(option)
|
---|
278 | {
|
---|
279 | option.setAttribute("onclick", "removeZoom();");
|
---|
280 | }
|
---|
281 | }
|
---|
282 | function removeZoom()
|
---|
283 | {
|
---|
284 | if(!_zoomEnabled)
|
---|
285 | {
|
---|
286 | return;
|
---|
287 | }
|
---|
288 |
|
---|
289 | var wrapper = document.getElementById("wrap");
|
---|
290 | var noZoom = document.getElementById("noZoom");
|
---|
291 |
|
---|
292 | if(!noZoom || !wrapper)
|
---|
293 | {
|
---|
294 | return;
|
---|
295 | }
|
---|
296 |
|
---|
297 | wrapper.style.display = "none";
|
---|
298 | noZoom.style.display = "block";
|
---|
299 | var option = document.getElementById("zoomOption");
|
---|
300 | if(option)
|
---|
301 | {
|
---|
302 | option.setAttribute("onclick", "addZoom();");
|
---|
303 | }
|
---|
304 | }
|
---|
305 | </xsl:text> </script>
|
---|
306 | <script text="text/javascript">
|
---|
307 | <xsl:text disable-output-escaping="yes">var _posCount = 0;
|
---|
308 | var _notes;
|
---|
309 | function initNotes()
|
---|
310 | {
|
---|
311 | /* create the Photo Note Container */
|
---|
312 | _notes = new PhotoNoteContainer(document.getElementById("noZoom"));
|
---|
313 | getNotes();
|
---|
314 | }
|
---|
315 |
|
---|
316 | function deleteFunction(note)
|
---|
317 | {
|
---|
318 | var status = true;
|
---|
319 |
|
---|
320 | if (note && note.id && note.id > 0) {
|
---|
321 | var metaposStr = note.id - 1;
|
---|
322 |
|
---|
323 | var jsonVal = '{"caption":"' + note.text + '", "area":{"x":' + note.rect.left + ', "y":' + note.rect.top + ', "width":' + note.rect.width + ', "height":' + note.rect.height + '}}';
|
---|
324 |
|
---|
325 | var removeFromIndexURL = "cgi-bin/metadata-server.pl?a=remove-metadata&site=localsite&c=" + gs.cgiParams.c + "&d=" + gs.cgiParams.d + "&metaname=gsimg.photoNote&metapos=" + metaposStr;
|
---|
326 | var removeFromArchivesURL = "cgi-bin/metadata-server.pl?a=remove-archives-metadata&site=localsite&c=" + gs.cgiParams.c + "&d=" + gs.cgiParams.d + "&metaname=gsimg.photoNote&metapos=" + metaposStr;
|
---|
327 | var removeFromImportURL = "cgi-bin/metadata-server.pl?a=remove-import-metadata&site=localsite&c=" + gs.cgiParams.c + "&d=" + gs.cgiParams.d + "&metaname=gsimg.photoNote&metavalue=" + jsonVal;
|
---|
328 |
|
---|
329 | var indexCallback =
|
---|
330 | {
|
---|
331 | success: function(response)
|
---|
332 | {
|
---|
333 | for(var i = 0; i < _notes.length; i++)
|
---|
334 | {
|
---|
335 | var currentNote = _notes[i];
|
---|
336 | if(currentNote.id > note.id)
|
---|
337 | {
|
---|
338 | currentNote.id--;
|
---|
339 | }
|
---|
340 | }
|
---|
341 | _posCount--;
|
---|
342 | },
|
---|
343 | failed: function(){alert("Failed to delete index metadata of note with id: " + note.id);},
|
---|
344 | };
|
---|
345 |
|
---|
346 | var archiveCallback =
|
---|
347 | {
|
---|
348 | success: function(){buildFunction(gs.cgiParams.c);},
|
---|
349 | failed: function(){alert("Failed to delete archive metadata of note with id: " + note.id);}
|
---|
350 | }
|
---|
351 |
|
---|
352 | var importCallback =
|
---|
353 | {
|
---|
354 | success: function(){},
|
---|
355 | failed: function(){alert("Failed to delete import metadata of note with id: " + note.id);}
|
---|
356 | }
|
---|
357 |
|
---|
358 | YAHOO.util.Connect.asyncRequest("GET", removeFromIndexURL, indexCallback);
|
---|
359 | YAHOO.util.Connect.asyncRequest("GET", removeFromArchivesURL, archiveCallback);
|
---|
360 | YAHOO.util.Connect.asyncRequest("GET", removeFromImportURL, importCallback);
|
---|
361 | }
|
---|
362 | else {
|
---|
363 | alert("Failed to find valid note data to delete");
|
---|
364 | status = false;
|
---|
365 | }
|
---|
366 |
|
---|
367 | return status;
|
---|
368 | }
|
---|
369 |
|
---|
370 | function saveFunction(note)
|
---|
371 | {
|
---|
372 | var saveIndexCallback =
|
---|
373 | {
|
---|
374 | success: function(response){},
|
---|
375 | failed: function(reponse){ alert("Failed to save index metadata of note with id: " + note.id)},
|
---|
376 | };
|
---|
377 |
|
---|
378 | var saveArchivesCallback =
|
---|
379 | {
|
---|
380 | success: function(response){buildFunction(gs.cgiParams.c);},
|
---|
381 | failed: function(response){ alert("Failed in save import metadata of note with id: " + note.id) }
|
---|
382 | };
|
---|
383 |
|
---|
384 | var saveImportCallback =
|
---|
385 | {
|
---|
386 | success: function(response){},
|
---|
387 | failed: function(response){ alert("Failed in save import metadata of note with id: " + note.id) }
|
---|
388 | };
|
---|
389 |
|
---|
390 | var jsonVal = '{"caption":"' + note.text + '", "area":{"x":' + note.rect.left + ', "y":' + note.rect.top + ', "width":' + note.rect.width + ', "height":' + note.rect.height + '}}';
|
---|
391 | var metaposStr = (note && note.id && note.id > 0) ? note.id - 1 : _posCount;
|
---|
392 |
|
---|
393 | var saveIndexURL = "cgi-bin/metadata-server.pl?a=set-metadata&site=localsite&c=" + gs.cgiParams.c + "&d=" + gs.cgiParams.d + "&metaname=gsimg.photoNote&metamode=override&metavalue=" + jsonVal + "&metapos=" + metaposStr;
|
---|
394 | var saveArchivesURL = "cgi-bin/metadata-server.pl?a=set-archives-metadata&site=localsite&c=" + gs.cgiParams.c + "&d=" + gs.cgiParams.d + "&metaname=gsimg.photoNote&metamode=override&metavalue=" + jsonVal + "&metapos=" + metaposStr;
|
---|
395 | var saveImportURL = "cgi-bin/metadata-server.pl?a=set-import-metadata&site=localsite&c=" + gs.cgiParams.c + "&d=" + gs.cgiParams.d + "&metaname=gsimg.photoNote&metamode=override&metavalue=" + jsonVal + "&metapos=" + metaposStr;
|
---|
396 | YAHOO.util.Connect.asyncRequest("GET", saveIndexURL, saveIndexCallback);
|
---|
397 | YAHOO.util.Connect.asyncRequest("GET", saveArchivesURL, saveArchivesCallback);
|
---|
398 | YAHOO.util.Connect.asyncRequest("GET", saveImportURL, saveImportCallback);
|
---|
399 |
|
---|
400 | return 1;
|
---|
401 | }
|
---|
402 |
|
---|
403 | function getNotes()
|
---|
404 | {
|
---|
405 | if(gs.variables.photoNotes == null || gs.variables.photoNotes == undefined)
|
---|
406 | {
|
---|
407 | console.log("No photo notes");
|
---|
408 | return;
|
---|
409 | }
|
---|
410 |
|
---|
411 | for(var i = 0; i < gs.variables.photoNotes.length; i++)
|
---|
412 | {
|
---|
413 | var note = gs.variables.photoNotes[i];
|
---|
414 | if(!note)
|
---|
415 | {
|
---|
416 | continue;
|
---|
417 | }
|
---|
418 | var newNote = new PhotoNote(note.caption, i+1, new PhotoNoteRect(note.area.x,note.area.y,note.area.width,note.area.height));
|
---|
419 | newNote.onsave = saveFunction;
|
---|
420 | newNote.ondelete = deleteFunction;
|
---|
421 | _notes.AddNote(newNote);
|
---|
422 | _posCount++;
|
---|
423 | }
|
---|
424 |
|
---|
425 | addNoteOverAndOutHandlers();
|
---|
426 | }
|
---|
427 |
|
---|
428 | function AddNote()
|
---|
429 | {
|
---|
430 | var photoPos = $("#noZoom").offset();
|
---|
431 | var newNote = new PhotoNote('Add note text here...',_posCount+1,new PhotoNoteRect(20,20,50,50));
|
---|
432 | newNote.onsave = saveFunction;
|
---|
433 | newNote.ondelete = deleteFunction;
|
---|
434 | _notes.AddNote(newNote);
|
---|
435 | _posCount++;
|
---|
436 |
|
---|
437 | addNoteOverAndOutHandlers();
|
---|
438 | newNote.Select();
|
---|
439 | }
|
---|
440 |
|
---|
441 | function addNoteOverAndOutHandlers()
|
---|
442 | {
|
---|
443 | var divs = document.getElementsByTagName("DIV");
|
---|
444 | for(var i = 0; i < divs.length; i++)
|
---|
445 | {
|
---|
446 | if(divs[i].getAttribute("class") && divs[i].getAttribute("class").search("fn-area") != -1)
|
---|
447 | {
|
---|
448 | divs[i].onmouseover = function(){_zoomEnabled = false;}
|
---|
449 | divs[i].onmouseout = function(){_zoomEnabled = true;}
|
---|
450 | }
|
---|
451 | }
|
---|
452 | }
|
---|
453 |
|
---|
454 | function addStatusBar()
|
---|
455 | {
|
---|
456 | var textDiv = document.getElementById("gs-document");
|
---|
457 | var buildStatusBar = document.createElement("div");
|
---|
458 | buildStatusBar.setAttribute("id", "buildStatusBar");
|
---|
459 | buildStatusBar.setAttribute("class", "ui-state-default ui-corner-all");
|
---|
460 | buildStatusBar.setAttribute("style", "visibility:hidden; width:100%");
|
---|
461 | var buildingMessage = document.createElement("div");
|
---|
462 | buildingMessage.setAttribute("id", "buildMessage");
|
---|
463 | buildingMessage.setAttribute("style", "width:50%; padding:3px; margin:5px auto; text-align:center;");
|
---|
464 | buildStatusBar.appendChild(buildingMessage);
|
---|
465 |
|
---|
466 | textDiv.insertBefore(buildStatusBar, textDiv.firstChild);
|
---|
467 | }
|
---|
468 |
|
---|
469 | function prepopulateAnnotatorSearchBar()
|
---|
470 | {
|
---|
471 | if(gs.cgiParams.s1_query && gs.cgiParams.s1_index == "GE")
|
---|
472 | {
|
---|
473 | $("#annotator-filter-text").val(gs.cgiParams.s1_query).keyup().blur();
|
---|
474 | console.log("AAA");
|
---|
475 | }
|
---|
476 |
|
---|
477 | if(gs.cgiParams.s1_query && gs.cgiParams.s1_index == "GT")
|
---|
478 | {
|
---|
479 | $("#annotator-filter-tags").val(gs.cgiParams.s1_query).keyup().blur();
|
---|
480 | console.log("BBB");
|
---|
481 | }
|
---|
482 |
|
---|
483 | if(gs.cgiParams.s1_query && gs.cgiParams.s1_index == "GX")
|
---|
484 | {
|
---|
485 | $("#annotator-filter-user").val(gs.cgiParams.s1_query).keyup().blur();
|
---|
486 | console.log("CCC");
|
---|
487 | }
|
---|
488 | }
|
---|
489 |
|
---|
490 | function addPrevNextPageButtons()
|
---|
491 | {
|
---|
492 | var buttonDiv = document.createElement("DIV");
|
---|
493 | var buttonTable = document.createElement("TABLE");
|
---|
494 | var buttonRow = document.createElement("TR");
|
---|
495 | var buttonPrevCell = document.createElement("TD");
|
---|
496 | var buttonNextCell = document.createElement("TD");
|
---|
497 | buttonRow.appendChild(buttonPrevCell);
|
---|
498 | buttonRow.appendChild(buttonNextCell);
|
---|
499 | buttonTable.appendChild(buttonRow);
|
---|
500 | buttonDiv.appendChild(buttonTable);
|
---|
501 |
|
---|
502 | buttonDiv.setAttribute("style", "width:100%");
|
---|
503 | buttonTable.setAttribute("style", "margin:auto;");
|
---|
504 | buttonPrevCell.setAttribute("style", "padding:10px;");
|
---|
505 | buttonNextCell.setAttribute("style", "padding:10px;");
|
---|
506 |
|
---|
507 | document.getElementById("gs-document-text").appendChild(buttonDiv);
|
---|
508 |
|
---|
509 | gs.functions.getArchivesMetadata(gs.cgiParams.c, "localsite", gs.cgiParams.d, "SourceFile", null, function(meta)
|
---|
510 | {
|
---|
511 | var sourceFilename = meta.getValue();
|
---|
512 | var fileNameSegments = sourceFilename.split("-");
|
---|
513 | var finalSegment = fileNameSegments[fileNameSegments.length-1];
|
---|
514 |
|
---|
515 | var extIndex = finalSegment.indexOf(".");
|
---|
516 | var ext = "";
|
---|
517 | if(extIndex != -1)
|
---|
518 | {
|
---|
519 | ext = finalSegment.substring(extIndex);
|
---|
520 | finalSegment = finalSegment.substring(0, extIndex);
|
---|
521 | }
|
---|
522 | var finalNumber = parseInt(finalSegment);
|
---|
523 |
|
---|
524 | var prevFilename = "";
|
---|
525 | var nextFilename = "";
|
---|
526 | for(var i = 0; i < fileNameSegments.length - 1; i++)
|
---|
527 | {
|
---|
528 | prevFilename += fileNameSegments[i] + "-";
|
---|
529 | nextFilename += fileNameSegments[i] + "-";
|
---|
530 | }
|
---|
531 |
|
---|
532 | if(finalNumber - 1 >= 0)
|
---|
533 | {
|
---|
534 | var prevFinalNumber = "" + (finalNumber - 1);
|
---|
535 | while(prevFinalNumber.length < finalSegment.length)
|
---|
536 | {
|
---|
537 | prevFinalNumber = "0" + prevFinalNumber;
|
---|
538 | }
|
---|
539 | prevFilename += prevFinalNumber + ext;
|
---|
540 |
|
---|
541 | prevButtonCallback =
|
---|
542 | {
|
---|
543 | success:function(response)
|
---|
544 | {
|
---|
545 | var text = response.responseText;
|
---|
546 | var startIndex = text.indexOf("nodeID=\"");
|
---|
547 | if(startIndex == -1)
|
---|
548 | {
|
---|
549 | return;
|
---|
550 | }
|
---|
551 | startIndex += 8;
|
---|
552 | endIndex = text.indexOf("\"", startIndex + 1);
|
---|
553 |
|
---|
554 | var id = text.substring(startIndex, endIndex);
|
---|
555 |
|
---|
556 | var prevLink = document.createElement("A");
|
---|
557 | prevLink.innerHTML = "Previous Page";
|
---|
558 | prevLink.setAttribute("href", gs.xsltParams.library_name + "?a=d&d=" + id + "&c=" + gs.cgiParams.c + "&dt=hierarchy&ed=1");
|
---|
559 | buttonPrevCell.appendChild(prevLink);
|
---|
560 | },
|
---|
561 | failed:function(response){console.log("Search for previous document failed");}
|
---|
562 | }
|
---|
563 | YAHOO.util.Connect.asyncRequest("GET", gs.xsltParams.library_name + "?a=q&sa=&rt=rd&s=TextQuery&c=peijones&startPage=1&s1.query=" + prevFilename.replace(/-/g, " ") + "&s1.index=SO&o=xml", prevButtonCallback);
|
---|
564 | }
|
---|
565 |
|
---|
566 | var nextFinalNumber = "" + (finalNumber + 1);
|
---|
567 | while(nextFinalNumber.length < finalSegment.length)
|
---|
568 | {
|
---|
569 | nextFinalNumber = "0" + nextFinalNumber;
|
---|
570 | }
|
---|
571 | nextFilename += nextFinalNumber + ext;
|
---|
572 |
|
---|
573 | nextButtonCallback =
|
---|
574 | {
|
---|
575 | success:function(response)
|
---|
576 | {
|
---|
577 | var text = response.responseText;
|
---|
578 | var startIndex = text.indexOf("nodeID=\"");
|
---|
579 | if(startIndex == -1)
|
---|
580 | {
|
---|
581 | return;
|
---|
582 | }
|
---|
583 | startIndex += 8;
|
---|
584 | endIndex = text.indexOf("\"", startIndex + 1);
|
---|
585 |
|
---|
586 | var id = text.substring(startIndex, endIndex);
|
---|
587 |
|
---|
588 | var nextLink = document.createElement("A");
|
---|
589 | nextLink.innerHTML = "Next Page";
|
---|
590 | nextLink.setAttribute("href", gs.xsltParams.library_name + "?a=d&d=" + id + "&c=" + gs.cgiParams.c + "&dt=hierarchy&ed=1");
|
---|
591 | buttonNextCell.appendChild(nextLink);
|
---|
592 | },
|
---|
593 | failed:function(response){console.log("Search for next document failed");}
|
---|
594 | }
|
---|
595 |
|
---|
596 | YAHOO.util.Connect.asyncRequest("GET", gs.xsltParams.library_name + "?a=q&sa=&rt=rd&s=TextQuery&c=peijones&startPage=1&s1.query=" + nextFilename.replace(/-/g, " ") + "&s1.index=SO&o=xml", nextButtonCallback);
|
---|
597 | });
|
---|
598 | }
|
---|
599 |
|
---|
600 | function addSocialLinks()
|
---|
601 | {
|
---|
602 | var socialLinksDiv = document.createElement("DIV");
|
---|
603 | socialLinksDiv.setAttribute("class", "addthis_toolbox addthis_default_style");
|
---|
604 |
|
---|
605 | var facebookLink = document.createElement("A");
|
---|
606 | facebookLink.setAttribute("class", "addthis_button_facebook_like");
|
---|
607 | facebookLink.setAttribute("fb:like:layout", "button_count");
|
---|
608 | socialLinksDiv.appendChild(facebookLink);
|
---|
609 |
|
---|
610 | var twitterLink = document.createElement("A");
|
---|
611 | twitterLink.setAttribute("class", "addthis_button_tweet");
|
---|
612 | socialLinksDiv.appendChild(twitterLink);
|
---|
613 |
|
---|
614 | var gplusLink = document.createElement("A");
|
---|
615 | gplusLink.setAttribute("class", "addthis_button_google_plusone");
|
---|
616 | gplusLink.setAttribute("g:plusone:size", "medium");
|
---|
617 | socialLinksDiv.appendChild(gplusLink);
|
---|
618 |
|
---|
619 | var addThisLink = document.createElement("A");
|
---|
620 | addThisLink.setAttribute("class", "addthis_counter addthis_pill_style");
|
---|
621 | socialLinksDiv.appendChild(addThisLink);
|
---|
622 |
|
---|
623 | var script = document.createElement("SCRIPT");
|
---|
624 | script.setAttribute("type", "text/javascript");
|
---|
625 | script.setAttribute("src", "http://s7.addthis.com/js/250/addthis_widget.js#pubid=xa-4f5fe0cf41940d54");
|
---|
626 | socialLinksDiv.appendChild(script);
|
---|
627 |
|
---|
628 | document.getElementById("gs-document-text").appendChild(socialLinksDiv);
|
---|
629 | }
|
---|
630 |
|
---|
631 | </xsl:text>
|
---|
632 | <xsl:if test="not(/page/pageRequest/paramList/param[@name ='p.docEdit'])">
|
---|
633 | <xsl:text disable-output-escaping="yes">
|
---|
634 | $(window).load(function(){readyImagesForZoom(); initAnnotator(); addStatusBar(); initNotes(); addPrevNextPageButtons(); addSocialLinks(); });
|
---|
635 | </xsl:text>
|
---|
636 | </xsl:if>
|
---|
637 | </script>
|
---|
638 | <script text="text/javascript">
|
---|
639 | <xsl:text disable-output-escaping="yes">function checkLoop(pid, serverFunction, callback)
|
---|
640 | {
|
---|
641 | var startLoop = function()
|
---|
642 | {
|
---|
643 | var loopCallback =
|
---|
644 | {
|
---|
645 | success:function(response)
|
---|
646 | {
|
---|
647 | var checkText = response.responseText;
|
---|
648 | if(checkText == null || checkText == "")
|
---|
649 | {
|
---|
650 | console.log("There was an error getting the XML to check the status of " + serverFunction);
|
---|
651 | }
|
---|
652 | else
|
---|
653 | {
|
---|
654 | var checkCodeStart = checkText.indexOf("code=\"") + 6;
|
---|
655 | var checkCodeEnd = checkText.indexOf("\"", checkCodeStart);
|
---|
656 | var code = checkText.substring(checkCodeStart, checkCodeEnd);
|
---|
657 |
|
---|
658 | if(code == 11 || code == 1) //11 is COMPLETED, 1 is success
|
---|
659 | {
|
---|
660 | callback();
|
---|
661 | }
|
---|
662 | else if(code == 12 || code == 3) //12 is HALTED, 3 is ERROR
|
---|
663 | {
|
---|
664 | console.log("There was an error on the server, could not check status of " + serverFunction);
|
---|
665 | }
|
---|
666 | else
|
---|
667 | {
|
---|
668 | setTimeout(startLoop, 1000);
|
---|
669 | }
|
---|
670 | }
|
---|
671 | },
|
---|
672 | failed:function()
|
---|
673 | {
|
---|
674 | console.log("There was a problem checking the status of " + serverFunction)
|
---|
675 | }
|
---|
676 | }
|
---|
677 | YAHOO.util.Connect.asyncRequest("GET", gs.xsltParams.library_name + "?a=g&rt=s&ro=1&s=" + serverFunction + "&s1.pid=" + pid, loopCallback);
|
---|
678 | }
|
---|
679 | startLoop();
|
---|
680 | }
|
---|
681 |
|
---|
682 | function buildFunction(collection)
|
---|
683 | {
|
---|
684 | var buildCallback =
|
---|
685 | {
|
---|
686 | success:function(response)
|
---|
687 | {
|
---|
688 | var buildText = response.responseText;
|
---|
689 | if(buildText == null || buildText == "")
|
---|
690 | {
|
---|
691 | console.log("There was an error getting the xml response from the building request");
|
---|
692 | }
|
---|
693 | else
|
---|
694 | {
|
---|
695 | var buildPIDStart = buildText.indexOf("pid=\"") + 5;
|
---|
696 | var buildPIDEnd = buildText.indexOf("\"", buildPIDStart);
|
---|
697 | var buildPID = buildText.substring(buildPIDStart, buildPIDEnd);
|
---|
698 |
|
---|
699 | checkLoop(buildPID, "BuildCollection", function()
|
---|
700 | {
|
---|
701 | var activateCallback =
|
---|
702 | {
|
---|
703 | success: function(response)
|
---|
704 | {
|
---|
705 | var activateText = response.responseText;
|
---|
706 | if(activateText == null || activateText == "")
|
---|
707 | {
|
---|
708 | console.log("There was an error getting the xml response from the activating request");
|
---|
709 | }
|
---|
710 | else
|
---|
711 | {
|
---|
712 | var activatePIDStart = activateText.indexOf("pid=\"") + 5;
|
---|
713 | var activatePIDEnd = activateText.indexOf("\"", activatePIDStart);
|
---|
714 | var activatePID = activateText.substring(activatePIDStart, activatePIDEnd);
|
---|
715 |
|
---|
716 | checkLoop(activatePID, "ActivateCollection", function()
|
---|
717 | {
|
---|
718 | var updateCallback =
|
---|
719 | {
|
---|
720 | success: function(response){document.getElementById("buildStatusBar").style.visibility = "hidden";},
|
---|
721 | failed: function(reponse){ alert("Failed in saveFunction() to re-read config files"); document.getElementById("buildStatusBar").style.visibility = "hidden";}
|
---|
722 | };
|
---|
723 | YAHOO.util.Connect.asyncRequest("GET", gs.xsltParams.library_name + "?a=s&sa=c", updateCallback);
|
---|
724 | });
|
---|
725 | }
|
---|
726 | },
|
---|
727 | failed: function(response)
|
---|
728 | {
|
---|
729 | document.getElementById("buildStatusBar").style.visibility = "hidden";
|
---|
730 | console.log("Failed to get response from activate collection request");
|
---|
731 | }
|
---|
732 | }
|
---|
733 | YAHOO.util.Connect.asyncRequest("GET", gs.xsltParams.library_name + "?a=g&rt=r&ro=1&s=ActivateCollection&s1.collection=" + collection, activateCallback);
|
---|
734 | });
|
---|
735 | }
|
---|
736 | },
|
---|
737 | failed: function(){console.log("Failed to get build collection response"); document.getElementById("buildStatusBar").style.visibility = "hidden";}
|
---|
738 | }
|
---|
739 |
|
---|
740 | YAHOO.util.Connect.asyncRequest("GET", gs.xsltParams.library_name + "?a=g&rt=r&ro=1&s=BuildCollection&s1.collection=" + collection, buildCallback);
|
---|
741 | showBuildingMessage();
|
---|
742 | }
|
---|
743 |
|
---|
744 | function saveAndBuildCollection(col)
|
---|
745 | {
|
---|
746 | for(var j = 0; j < gs.toDeleteArray.keys.length; j++)
|
---|
747 | {
|
---|
748 | var current = gs.toDeleteArray[gs.toDeleteArray.keys[j]];
|
---|
749 | if(current == null){continue;}
|
---|
750 | var metaToDelete = ["user", "text", "tags"];
|
---|
751 | for(var l = 0; l < metaToDelete.length; l++)
|
---|
752 | {
|
---|
753 | var deleteArchivesURL = "cgi-bin/metadata-server.pl?\
|
---|
754 | a=remove-archives-metadata&\
|
---|
755 | c=" + gs.cgiParams.c + "&\
|
---|
756 | site=localsite&\
|
---|
757 | d=" + gs.cgiParams.d + "&\
|
---|
758 | metaname=gstext." + metaToDelete[l] + "&\
|
---|
759 | metavalue=" + ((l == 0) ? (current.user.name) : (current[metaToDelete[l]]));
|
---|
760 |
|
---|
761 | var deleteIndexURL = "cgi-bin/metadata-server.pl?\
|
---|
762 | a=remove-metadata&\
|
---|
763 | c=" + gs.cgiParams.c + "&\
|
---|
764 | site=localsite&\
|
---|
765 | d=" + gs.cgiParams.d + "&\
|
---|
766 | metaname=gstext." + metaToDelete[l] + "&\
|
---|
767 | metavalue=" + ((l == 0) ? (current.user.name) : (current[metaToDelete[l]]));
|
---|
768 |
|
---|
769 | var deleteImportURL = "cgi-bin/metadata-server.pl?\
|
---|
770 | a=remove-import-metadata&\
|
---|
771 | c=" + gs.cgiParams.c + "&\
|
---|
772 | site=localsite&\
|
---|
773 | d=" + gs.cgiParams.d + "&\
|
---|
774 | metaname=gstext." + metaToDelete[l] + "&\
|
---|
775 | metavalue=" + ((l == 0) ? (current.user.name) : (current[metaToDelete[l]]));
|
---|
776 | var deleteArchivesCallback =
|
---|
777 | {
|
---|
778 | success:function(){},
|
---|
779 | failed: function(){alert("Failed to save text annotations archives metadata");}
|
---|
780 | }
|
---|
781 | YAHOO.util.Connect.asyncRequest("GET", deleteArchivesURL, deleteArchivesCallback);
|
---|
782 |
|
---|
783 | var deleteIndexCallback =
|
---|
784 | {
|
---|
785 | success:function(){},
|
---|
786 | failed: function(){alert("Failed to save text annotations index metadata");}
|
---|
787 | }
|
---|
788 | YAHOO.util.Connect.asyncRequest("GET", deleteIndexURL, deleteIndexCallback);
|
---|
789 |
|
---|
790 | var deleteImportCallback =
|
---|
791 | {
|
---|
792 | success:function(){},
|
---|
793 | failed: function(){alert("Failed to save text annotations import metadata");}
|
---|
794 | }
|
---|
795 | YAHOO.util.Connect.asyncRequest("GET", deleteImportURL, deleteImportCallback);
|
---|
796 | }
|
---|
797 | }
|
---|
798 | gs.toDeleteArray = new Array();
|
---|
799 | gs.toDeleteArray.keys = new Array();
|
---|
800 |
|
---|
801 | if(gs.annotationArray.keys.length > 0)
|
---|
802 | {
|
---|
803 | var json = "[";
|
---|
804 | for(var i = 0; i < gs.annotationArray.keys.length; i++)
|
---|
805 | {
|
---|
806 | var current = gs.annotationArray[gs.annotationArray.keys[i]];
|
---|
807 | if(current == null){continue;}
|
---|
808 | var metaToAdd = ["user", "text", "tags"];
|
---|
809 |
|
---|
810 | for(var j = 0; j < metaToAdd.length; j++)
|
---|
811 | {
|
---|
812 | if(metaToAdd[j] == "user")
|
---|
813 | {
|
---|
814 | json += '{"docid":"' + gs.cgiParams.d + '", "metaname":"gstext.' + metaToAdd[j] + '", "metavalue":"' + current.user.name + '"}';
|
---|
815 | }
|
---|
816 | else
|
---|
817 | {
|
---|
818 | json += '{"docid":"' + gs.cgiParams.d + '", "metaname":"gstext.' + metaToAdd[j] + '", "metavalue":"' + current[metaToAdd[j]] + '"}';
|
---|
819 | }
|
---|
820 |
|
---|
821 | if(j != (metaToAdd.length - 1) || i != (gs.annotationArray.keys.length - 1))
|
---|
822 | {
|
---|
823 | json += ',';
|
---|
824 | }
|
---|
825 | }
|
---|
826 | }
|
---|
827 | json += "]";
|
---|
828 |
|
---|
829 | var saveArchivesURL = "cgi-bin/metadata-server.pl?a=set-archives-metadata-array&c=" + gs.cgiParams.c + "&site=localsite&collect=" + gs.cgiParams.c + "&json=" + json;
|
---|
830 | var saveIndexURL = "cgi-bin/metadata-server.pl?a=set-metadata-array&c=" + gs.cgiParams.c + "&site=localsite&collect=" + gs.cgiParams.c + "&json=" + json;
|
---|
831 | var saveImportURL = "cgi-bin/metadata-server.pl?a=set-import-metadata-array&c=" + gs.cgiParams.c + "&site=localsite&collect=" + gs.cgiParams.c + "&json=" + json;
|
---|
832 |
|
---|
833 | var saveArchivesCallback =
|
---|
834 | {
|
---|
835 | success:function(){console.log("Away to build"); buildFunction(gs.cgiParams.c);},
|
---|
836 | failed: function(){alert("Failed to save text annotations index metadata");}
|
---|
837 | }
|
---|
838 | YAHOO.util.Connect.asyncRequest("GET", saveArchivesURL, saveArchivesCallback);
|
---|
839 |
|
---|
840 | var saveIndexCallback =
|
---|
841 | {
|
---|
842 | success:function(){},
|
---|
843 | failed: function(){alert("Failed to save text annotations import metadata");}
|
---|
844 | }
|
---|
845 | YAHOO.util.Connect.asyncRequest("GET", saveIndexURL, saveIndexCallback);
|
---|
846 |
|
---|
847 | var saveImportCallback =
|
---|
848 | {
|
---|
849 | success:function(){},
|
---|
850 | failed: function(){alert("Failed to save text annotations import metadata");}
|
---|
851 | }
|
---|
852 | YAHOO.util.Connect.asyncRequest("GET", saveImportURL, saveImportCallback);
|
---|
853 | }
|
---|
854 |
|
---|
855 | gs.annotationArray = new Array();
|
---|
856 | gs.annotationArray.keys = new Array();
|
---|
857 | }
|
---|
858 |
|
---|
859 | function showRebuildOption()
|
---|
860 | {
|
---|
861 | var buildStatusBar = document.getElementById("buildStatusBar");
|
---|
862 | buildStatusBar.style.visibility = "visible";
|
---|
863 |
|
---|
864 | var buildMessage = document.getElementById("buildMessage");
|
---|
865 | buildMessage.innerHTML = 'Please rebuild to index annotations (make annotations searchable): <span id="rebuildButton" style="cursor:pointer; padding:2px;" class="ui-state-default ui-corner-all">Rebuild</span>';
|
---|
866 |
|
---|
867 | var rebuildButton = document.getElementById("rebuildButton");
|
---|
868 | rebuildButton.onclick = function(){saveAndBuildCollection("peijones");}
|
---|
869 | }
|
---|
870 |
|
---|
871 | function showBuildingMessage()
|
---|
872 | {
|
---|
873 | var buildStatusBar = document.getElementById("buildStatusBar");
|
---|
874 | buildStatusBar.style.visibility = "visible";
|
---|
875 |
|
---|
876 | var buildMessage = document.getElementById("buildMessage");
|
---|
877 | buildMessage.innerHTML = '<img src="' + gs.imageURLs.loading + '"/> Building...';
|
---|
878 | }
|
---|
879 |
|
---|
880 | function initAnnotator()
|
---|
881 | {
|
---|
882 | gs.annotationArray = new Array();
|
---|
883 | gs.annotationArray.keys = new Array();
|
---|
884 |
|
---|
885 | gs.toDeleteArray = new Array();
|
---|
886 | gs.toDeleteArray.keys = new Array();
|
---|
887 |
|
---|
888 | var elem = document.getElementById("gs-document-text");
|
---|
889 | elem.innerHTML = '<div><span style="visibility:hidden; padding: 3px;" class="ui-state-default ui-corner-all" id="saveButton">Reindex annotations</span></div><br/>' + elem.innerHTML;
|
---|
890 |
|
---|
891 | if (typeof $.fn.annotator !== 'function')
|
---|
892 | {
|
---|
893 | alert("Ooops! it looks like you haven't built the Annotator concatenation file. " + "Either download a tagged release from GitHub, or modify the Cakefile to point " + "at your copy of the YUI compressor and run `cake package`.");
|
---|
894 | }
|
---|
895 | else
|
---|
896 | {
|
---|
897 | // Include AnnotateIt credentials to load the store plugin.
|
---|
898 | $('#gs-document-text').annotator().annotator('setupPlugins', {
|
---|
899 | userId: 'papitha',
|
---|
900 | userName: 'Papitha',
|
---|
901 | accountId: '39fc339cf058bd22176771b3e33c5dac',
|
---|
902 | authToken: '852b7fc25396d2aedf9aeb44dd58518faa679dbf027892164bfb81900bd09741',
|
---|
903 | // $('#gs-document-text').annotator().annotator('setupPlugins', {
|
---|
904 | // userId: 'david',
|
---|
905 | // userName: 'David',
|
---|
906 | // accountId: 'eb096fae65f6377160ffc0eb6c000951',
|
---|
907 | // authToken: '92b3279a6b6edbaa2ed7bc4d895ef55c8f1368877bb69987985aa47195d517e7',
|
---|
908 | }, {
|
---|
909 | Store:
|
---|
910 | {
|
---|
911 | prefix: 'http://localhost:5000',
|
---|
912 | annotationData: {'uri':gs.cgiParams.c + "-" + gs.cgiParams.d},
|
---|
913 | loadFromSearch: {'uri':gs.cgiParams.c + "-" + gs.cgiParams.d}
|
---|
914 | }
|
---|
915 | });
|
---|
916 | }
|
---|
917 | }
|
---|
918 | </xsl:text> </script>
|
---|
919 | </xsl:template>
|
---|
920 | <xsl:template name="documentImage">
|
---|
921 | <!-- Get the photo notes for this document node --> <gsf:variable-struct name="photoNotes">
|
---|
922 | <gsf:metadata multiple="true" name="gsimg.photoNote" separator=", "/>
|
---|
923 | </gsf:variable-struct>
|
---|
924 | <!-- Get details about the image for zooming --> <h3>
|
---|
925 | <gsf:choose-metadata>
|
---|
926 | <gsf:metadata name="dc.Title"/>
|
---|
927 | <gsf:metadata name="ex.Title"/>
|
---|
928 | </gsf:choose-metadata>
|
---|
929 | </h3>
|
---|
930 | <xsl:variable name="imageWidth">
|
---|
931 | <gsf:choose-metadata>
|
---|
932 | <gsf:metadata name="ImageWidth"/>
|
---|
933 | <gsf:default>-1</gsf:default>
|
---|
934 | </gsf:choose-metadata>
|
---|
935 | </xsl:variable>
|
---|
936 | <xsl:variable name="imageHeight">
|
---|
937 | <gsf:choose-metadata>
|
---|
938 | <gsf:metadata name="ImageHeight"/>
|
---|
939 | <gsf:default>-1</gsf:default>
|
---|
940 | </gsf:choose-metadata>
|
---|
941 | </xsl:variable>
|
---|
942 | <xsl:variable name="screenImageWidth">
|
---|
943 | <gsf:choose-metadata>
|
---|
944 | <gsf:metadata name="ScreenWidth"/>
|
---|
945 | <gsf:default>-1</gsf:default>
|
---|
946 | </gsf:choose-metadata>
|
---|
947 | </xsl:variable>
|
---|
948 | <xsl:variable name="screenImageHeight">
|
---|
949 | <gsf:choose-metadata>
|
---|
950 | <gsf:metadata name="ScreenHeight"/>
|
---|
951 | <gsf:default>-1</gsf:default>
|
---|
952 | </gsf:choose-metadata>
|
---|
953 | </xsl:variable>
|
---|
954 | <script type="text/javascript">
|
---|
955 | <xsl:text>largeImageHeight = </xsl:text> <xsl:value-of select="$imageHeight"/>
|
---|
956 | <xsl:text>;</xsl:text>
|
---|
957 | <xsl:text>largeImageWidth = </xsl:text> <xsl:value-of select="$imageWidth"/>
|
---|
958 | <xsl:text>;</xsl:text>
|
---|
959 | <xsl:text>smallImageHeight = </xsl:text> <xsl:value-of select="$screenImageHeight"/>
|
---|
960 | <xsl:text>;</xsl:text>
|
---|
961 | <xsl:text>smallImageWidth = </xsl:text> <xsl:value-of select="$screenImageWidth"/>
|
---|
962 | <xsl:text>;</xsl:text>
|
---|
963 | </script>
|
---|
964 | <span class="ui-state-default ui-corner-top" onclick="AddNote();" style="font-size:90%; padding: 3px; cursor:pointer;">New Image Annotation </span> <div id="noZoom" style="display:block;">
|
---|
965 | <img id="noZoomImage" style="width: {$screenImageWidth}px; height: {$screenImageHeight}px;">
|
---|
966 | <xsl:attribute name="src"><xsl:value-of disable-output-escaping="yes" select="/page/pageResponse/collection/metadataList/metadata[@name='httpPath']"/>/index/assoc/<gsf:metadata name="assocfilepath" select="root"/>/<gsf:metadata name="Screen"/></xsl:attribute>
|
---|
967 | </img>
|
---|
968 | <!--
|
---|
969 | <gsf:metadata name="screenicon"/>
|
---|
970 | --> </div>
|
---|
971 | <!--<xsl:if test="$imageHeight != -1">--> <div id="wrap" style="display:none; width: {$screenImageWidth}px; height: {$screenImageHeight}px;">
|
---|
972 | <div id="small" style="width: {$screenImageWidth}px; height: {$screenImageHeight}px;">
|
---|
973 | <!--
|
---|
974 | <gsf:metadata name="screenicon"/>
|
---|
975 | --> <img id="smallImage" style="width: {$screenImageWidth}px; height: {$screenImageHeight}px;">
|
---|
976 | <xsl:attribute name="src"><xsl:value-of disable-output-escaping="yes" select="/page/pageResponse/collection/metadataList/metadata[@name='httpPath']"/>/index/assoc/<gsf:metadata name="assocfilepath" select="root"/>/<gsf:metadata name="Screen"/></xsl:attribute>
|
---|
977 | </img>
|
---|
978 | </div>
|
---|
979 | <div id="mover">
|
---|
980 | <div id="overlay">
|
---|
981 | <xsl:text> </xsl:text> </div>
|
---|
982 | <div id="large" style="width: {$imageWidth}px; height: {$imageHeight}px;">
|
---|
983 | <img id="largeImage" style="width: {$imageWidth}px; height: {$imageHeight}px;">
|
---|
984 | <xsl:attribute name="src"><xsl:value-of disable-output-escaping="yes" select="/page/pageResponse/collection/metadataList/metadata[@name='httpPath']"/>/index/assoc/<gsf:metadata name="assocfilepath" select="root"/>/<gsf:metadata name="srclinkFile"/></xsl:attribute>
|
---|
985 | </img>
|
---|
986 | </div>
|
---|
987 | </div>
|
---|
988 | </div>
|
---|
989 | <div class="btn btn-primary start" style="margin-bottom:5px;">
|
---|
990 | <a style="color:white;">
|
---|
991 | <xsl:attribute name="href">
|
---|
992 | <xsl:value-of select="$library_name"/>
|
---|
993 | <xsl:text>?downloadFile=</xsl:text>
|
---|
994 | <xsl:text>sites/localsite/collect/</xsl:text>
|
---|
995 | <xsl:value-of select="/page/pageResponse/collection/@name"/>
|
---|
996 | <xsl:text>/index/assoc/</xsl:text>
|
---|
997 | <gsf:metadata name="assocfilepath"/>
|
---|
998 | <xsl:text>/</xsl:text>
|
---|
999 | <gsf:metadata name="SourceFile"/>
|
---|
1000 | </xsl:attribute>
|
---|
1001 | <xsl:text>Download Image </xsl:text> </a>
|
---|
1002 | </div>
|
---|
1003 | <xsl:choose>
|
---|
1004 | <xsl:when test="/page/pageRequest/paramList/param[@name = 'p.oldUpload']/@value = 'true'"><!-- <form action="dev?a=d&c={/page/pageResponse/collection/@name}&d={/page/pageResponse/document/documentNode/@nodeID}&dt=simple&ed=1" enctype="multipart/form-data" method="post">
|
---|
1005 | <input name="fl" type="hidden">
|
---|
1006 | <xsl:attribute name="value">
|
---|
1007 | <xsl:text>/sites/localsite/collect/</xsl:text>
|
---|
1008 | <xsl:value-of select="/page/pageResponse/collection/@name"/>
|
---|
1009 | <xsl:text>/index/assoc/</xsl:text>
|
---|
1010 | <gsf:metadata name="assocfilepath"/>
|
---|
1011 | <xsl:text>/</xsl:text>
|
---|
1012 | <gsf:metadata name="SourceFile"/>
|
---|
1013 | <xsl:text>:</xsl:text>
|
---|
1014 | <xsl:text>/sites/localsite/collect/</xsl:text>
|
---|
1015 | <xsl:value-of select="/page/pageResponse/collection/@name"/>
|
---|
1016 | <xsl:text>/index/assoc/</xsl:text>
|
---|
1017 | <gsf:metadata name="assocfilepath"/>
|
---|
1018 | <xsl:text>/</xsl:text>
|
---|
1019 | <gsf:metadata name="Screen"/>
|
---|
1020 | <xsl:text>:</xsl:text>
|
---|
1021 | <xsl:text>/sites/localsite/collect/</xsl:text>
|
---|
1022 | <xsl:value-of select="/page/pageResponse/collection/@name"/>
|
---|
1023 | <xsl:text>/index/assoc/</xsl:text>
|
---|
1024 | <gsf:metadata name="assocfilepath"/>
|
---|
1025 | <xsl:text>/</xsl:text>
|
---|
1026 | <gsf:metadata name="Thumb"/>
|
---|
1027 | </xsl:attribute>
|
---|
1028 | </input>
|
---|
1029 |
|
---|
1030 | <div>
|
---|
1031 | Upload replacement file:<br/>
|
---|
1032 | <input name="datafile" size="40" type="file"/><br/>
|
---|
1033 | <input type="submit" value="Send"/>
|
---|
1034 | </div>
|
---|
1035 | </form>--> </xsl:when> <xsl:otherwise>
|
---|
1036 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/tmpl.min.js">
|
---|
1037 | <xsl:text> </xsl:text> </script>
|
---|
1038 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/load-image.min.js">
|
---|
1039 | <xsl:text> </xsl:text> </script>
|
---|
1040 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.iframe-transport.js">
|
---|
1041 | <xsl:text> </xsl:text> </script>
|
---|
1042 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.fileupload.js">
|
---|
1043 | <xsl:text> </xsl:text> </script>
|
---|
1044 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.fileupload-ui.js">
|
---|
1045 | <xsl:text> </xsl:text> </script>
|
---|
1046 | <!--<script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/application.js"><xsl:text> </xsl:text></script>--> <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/bootstrap.min.js">
|
---|
1047 | <xsl:text> </xsl:text> </script>
|
---|
1048 | <script src="sites/localsite/collect/peijones/js/jQuery-File-Upload/bootstrap-image-gallery.min.js">
|
---|
1049 | <xsl:text> </xsl:text> </script>
|
---|
1050 | <link href="sites/localsite/collect/peijones/js/jQuery-File-Upload/jquery.fileupload-ui.css" rel="stylesheet"/>
|
---|
1051 | <link href="sites/localsite/collect/peijones/js/jQuery-File-Upload/bootstrap.min.css" rel="stylesheet"/>
|
---|
1052 | <link href="sites/localsite/collect/peijones/js/jQuery-File-Upload/bootstrap-responsive.min.css" rel="stylesheet"/>
|
---|
1053 | <!--[if lt IE 7]><link rel="stylesheet" href="http://blueimp.github.com/cdn/css/bootstrap-ie6.min.css"><![endif]--> <link href="sites/localsite/collect/peijones/js/jQuery-File-Upload/cors/bootstrap-image-gallery.min.css" rel="stylesheet"/>
|
---|
1054 | <script type="text/javascript">
|
---|
1055 | <xsl:text disable-output-escaping="yes">$(window).load(function()
|
---|
1056 | {
|
---|
1057 | $('#fileupload').fileupload();
|
---|
1058 | $('#fileupload').bind('fileuploaddone', function (e, data)
|
---|
1059 | {
|
---|
1060 | var nzImg = document.getElementById("noZoomImage");
|
---|
1061 | nzImg.setAttribute("src", nzImg.getAttribute("src") + "?" + (new Date()).getTime());
|
---|
1062 |
|
---|
1063 | var smallImg = document.getElementById("smallImage");
|
---|
1064 | smallImg.setAttribute("src", smallImg.getAttribute("src") + "?" + (new Date()).getTime());
|
---|
1065 |
|
---|
1066 | var largeImg = document.getElementById("largeImage");
|
---|
1067 | largeImg.setAttribute("src", largeImg.getAttribute("src") + "?" + (new Date()).getTime());
|
---|
1068 |
|
---|
1069 | readyImagesForZoom();
|
---|
1070 | });
|
---|
1071 | });
|
---|
1072 | </xsl:text> </script>
|
---|
1073 | <script id="template-upload" type="text/html">
|
---|
1074 | <xsl:text disable-output-escaping="yes">{% for (var i=0, files=o.files, l=files.length, file=files[0]; i<l; file=files[++i]) { %}
|
---|
1075 | <tr class="template-upload fade">
|
---|
1076 | <td class="preview"><span class="fade"></span></td>
|
---|
1077 | <td class="name">{%=file.name%}</td>
|
---|
1078 | <td class="size">{%=o.formatFileSize(file.size)%}</td>
|
---|
1079 | {% if (file.error) { %}
|
---|
1080 | <td class="error" colspan="2"><span class="label label-important">Error</span> {%=fileUploadErrors[file.error] || file.error%}</td>
|
---|
1081 | {% } else if (o.files.valid && !i) { %}
|
---|
1082 | <td>
|
---|
1083 | <div class="progress progress-success progress-striped active"><div class="bar" style="width:0%;"></div></div>
|
---|
1084 | </td>
|
---|
1085 | <td class="start">{% if (!o.options.autoUpload) { %}
|
---|
1086 | <button class="btn btn-primary">
|
---|
1087 | <i class="icon-upload icon-white"></i> Start
|
---|
1088 | </button>
|
---|
1089 | {% } %}</td>
|
---|
1090 | {% } else { %}
|
---|
1091 | <td colspan="2"></td>
|
---|
1092 | {% } %}
|
---|
1093 | <td class="cancel">{% if (!i) { %}
|
---|
1094 | <button class="btn btn-warning">
|
---|
1095 | <i class="icon-ban-circle icon-white"></i> Cancel
|
---|
1096 | </button>
|
---|
1097 | {% } %}</td>
|
---|
1098 | </tr>
|
---|
1099 | {% } %}
|
---|
1100 | </xsl:text> </script>
|
---|
1101 | <script id="template-download" type="text/html">
|
---|
1102 | <xsl:text disable-output-escaping="yes">{% for (var i=0, files=o.files, l=files.length, file=files[0]; i<l; file=files[++i]) { %}
|
---|
1103 | <tr class="template-download fade">
|
---|
1104 | {% if (file.error) { %}
|
---|
1105 | <td></td>
|
---|
1106 | <td class="name">{%=file.name%}</td>
|
---|
1107 | <td class="size">{%=o.formatFileSize(file.size)%}</td>
|
---|
1108 | <td class="error" colspan="2"><span class="label label-important">Error</span> {%=fileUploadErrors[file.error] || file.error%}</td>
|
---|
1109 | {% } else { %}
|
---|
1110 | <td class="preview">{% if (file.thumbnail_url) { %}
|
---|
1111 | <a href="{%=file.url%}" title="{%=file.name%}" rel="gallery"><img src="{%=file.thumbnail_url%}" style="height:100px;"/></a>
|
---|
1112 | {% } %}</td>
|
---|
1113 | <td class="name">
|
---|
1114 | <a href="{%=file.url%}" title="{%=file.name%}" rel="{%=file.thumbnail_url&&'gallery'%}">{%=file.name%}</a>
|
---|
1115 | </td>
|
---|
1116 | <td class="size">{%=o.formatFileSize(file.size)%}</td>
|
---|
1117 | <td colspan="2"></td>
|
---|
1118 | {% } %}
|
---|
1119 | </tr>
|
---|
1120 | {% } %}
|
---|
1121 | </xsl:text> </script>
|
---|
1122 | <form action="dev" enctype="multipart/form-data" id="fileupload" method="POST">
|
---|
1123 | <input name="ajaxUpload" type="hidden" value="true"/>
|
---|
1124 | <input name="fl" type="hidden">
|
---|
1125 | <xsl:attribute name="value">
|
---|
1126 | <xsl:text>/sites/localsite/collect/</xsl:text>
|
---|
1127 | <xsl:value-of select="/page/pageResponse/collection/@name"/>
|
---|
1128 | <xsl:text>/index/assoc/</xsl:text>
|
---|
1129 | <gsf:metadata name="assocfilepath"/>
|
---|
1130 | <xsl:text>/</xsl:text>
|
---|
1131 | <gsf:metadata name="SourceFile"/>
|
---|
1132 | <xsl:text>:</xsl:text>
|
---|
1133 | <xsl:text>/sites/localsite/collect/</xsl:text>
|
---|
1134 | <xsl:value-of select="/page/pageResponse/collection/@name"/>
|
---|
1135 | <xsl:text>/index/assoc/</xsl:text>
|
---|
1136 | <gsf:metadata name="assocfilepath"/>
|
---|
1137 | <xsl:text>/</xsl:text>
|
---|
1138 | <gsf:metadata name="Screen"/>
|
---|
1139 | <xsl:text>:</xsl:text>
|
---|
1140 | <xsl:text>/sites/localsite/collect/</xsl:text>
|
---|
1141 | <xsl:value-of select="/page/pageResponse/collection/@name"/>
|
---|
1142 | <xsl:text>/index/assoc/</xsl:text>
|
---|
1143 | <gsf:metadata name="assocfilepath"/>
|
---|
1144 | <xsl:text>/</xsl:text>
|
---|
1145 | <gsf:metadata name="Thumb"/>
|
---|
1146 | </xsl:attribute>
|
---|
1147 | </input>
|
---|
1148 | <div class="row fileupload-buttonbar">
|
---|
1149 | <div class="span6" style="margin-left:30px;">
|
---|
1150 | <span class="btn btn-success fileinput-button">
|
---|
1151 | <span>
|
---|
1152 | <i class="icon-plus icon-white">
|
---|
1153 | <xsl:text> </xsl:text> </i>
|
---|
1154 | Add files... </span>
|
---|
1155 | <input multiple="" name="files[]" type="file"/>
|
---|
1156 | </span>
|
---|
1157 | <button class="btn btn-primary start" type="submit">
|
---|
1158 | <i class="icon-upload icon-white">
|
---|
1159 | <xsl:text> </xsl:text> </i>
|
---|
1160 | Start upload
|
---|
1161 | </button>
|
---|
1162 | <button class="btn btn-warning cancel" type="reset">
|
---|
1163 | <i class="icon-ban-circle icon-white">
|
---|
1164 | <xsl:text> </xsl:text> </i>
|
---|
1165 | Cancel upload
|
---|
1166 | </button>
|
---|
1167 | </div>
|
---|
1168 | <div class="span6">
|
---|
1169 | <div class="progress progress-success progress-striped active fade">
|
---|
1170 | <div class="bar" style="width:0%;">
|
---|
1171 | <xsl:text> </xsl:text> </div>
|
---|
1172 | </div>
|
---|
1173 | </div>
|
---|
1174 | </div>
|
---|
1175 | <br/>
|
---|
1176 | <table class="table table-striped">
|
---|
1177 | <tbody class="files" data-target="#modal-gallery" data-toggle="modal-gallery">
|
---|
1178 | <xsl:text> </xsl:text> </tbody>
|
---|
1179 | </table>
|
---|
1180 | </form>
|
---|
1181 | </xsl:otherwise>
|
---|
1182 | </xsl:choose>
|
---|
1183 | <!--</xsl:if>--> </xsl:template>
|
---|
1184 | </format>
|
---|
1185 | </display>
|
---|
1186 | <replaceListRef id="gs2-standard"/>
|
---|
1187 | <replaceListRef id="gs2-image"/>
|
---|
1188 | <serviceRackList>
|
---|
1189 | <!-- comment out the following serviceRack if you want to disable OAI for this collection -->
|
---|
1190 |
|
---|
1191 | <serviceRack name="OAIPMH">
|
---|
1192 |
|
---|
1193 | <ListMetadataFormats>
|
---|
1194 | <!--What metadata sets to support is collection specific. To support other metadata schema, simply add a metadataFormat element here.
|
---|
1195 | The support of unqualified Dublin Core metadata set is mandatory in the oai specification.
|
---|
1196 | -->
|
---|
1197 |
|
---|
1198 | <metadataFormat metadataPrefix="oai_dc">
|
---|
1199 |
|
---|
1200 | <metadataPrefix>oai_dc</metadataPrefix>
|
---|
1201 |
|
---|
1202 | <schema>http://www.openarchives.org/OAI/2.0/oai_dc.xsd</schema>
|
---|
1203 |
|
---|
1204 | <metadataNamespace>http://www.openarchives.org/OAI/2.0/oai_dc/</metadataNamespace>
|
---|
1205 | <!--<metadataElements>dc.Title,dc.Creator,dc.Subject,dc.Description,dc.Publisher,dc.Contributor,dc.Date,dc.Type,dc.Format,dc.Identifier,dc.Source,dc.Language,dc.Relation,dc.Coverage,dc.Rights</metadataElements>
|
---|
1206 | -->
|
---|
1207 |
|
---|
1208 | <mappingList>
|
---|
1209 | <!--
|
---|
1210 | The mapping is in the form: <publicly supported metadata name>,<mapped metadata name>, short as <A>,<B>
|
---|
1211 | The first metadata name is medatory; if there is no mapped name followed, then the first name must be used by the records and
|
---|
1212 | searchable in the database, otherwise it is the mapped name stored in the database. The number of mapping elements matches the
|
---|
1213 | number of external metadata of the records. If only one name is present, the returned metadata will use this name plus the retrieved value;
|
---|
1214 | if both <A>,<B> are present, the returned metadata will use <A>'s name plus <B>'s value retrieved from database.
|
---|
1215 |
|
---|
1216 | **Bear in mind: if this mapping list is not present, the standard dc. metadata names (15 in total) will be used to retrieve metadata in the database.
|
---|
1217 |
|
---|
1218 | **The only case when this mapping is not present is that: 1. this metadata format is oai_dc; 2. the metadata is also stored in the database by Dublin Core's names.
|
---|
1219 | -->
|
---|
1220 |
|
---|
1221 | <mapping>dc.Title,Title</mapping>
|
---|
1222 | <!-- This mapping example means that the dc.Title is requested and the value of the metadata Title, which is used in this repository, is returned as response. -->
|
---|
1223 |
|
---|
1224 | </mappingList>
|
---|
1225 |
|
---|
1226 | </metadataFormat>
|
---|
1227 |
|
---|
1228 | </ListMetadataFormats>
|
---|
1229 |
|
---|
1230 | </serviceRack>
|
---|
1231 |
|
---|
1232 | </serviceRackList>
|
---|
1233 | </CollectionConfig>
|
---|