Skip to content

Commit 8e1c4ec

Browse files
committed
[bugfix] Prefix the elements in the TEI namespace that are returned from the API
1 parent e2b5446 commit 8e1c4ec

1 file changed

Lines changed: 19 additions & 18 deletions

File tree

src/main/formGenerator/config-mss.xml

Lines changed: 19 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -42,17 +42,17 @@
4242

4343
<!-- Add lookup options for elements with controlled vocabularly, must have an api already working. Example the Srophe apps person or places api -->
4444
<lookups>
45-
<lookup api="/exist/apps/majlis/api/search/mutual?format=xml&amp;q="
45+
<lookup api="/exist/apps/majlis/api/search/mutual?format=xml&amp;q="
4646
formURL="forms/msSimple/lookup/mutual.xhtml"
4747
elementName="mutual"
4848
formName="mutual"
4949
lookupLabel="Look up mutual relations."/>
50-
<lookup api="/exist/apps/majlis/api/search/active?format=xml&amp;q="
50+
<lookup api="/exist/apps/majlis/api/search/active?format=xml&amp;q="
5151
formURL="forms/msSimple/lookup/mutual.xhtml"
5252
elementName="active"
5353
formName="active"
5454
lookupLabel="Look up subject of relation."/>
55-
<lookup api="/exist/apps/majlis/api/search/passive?format=xml&amp;q="
55+
<lookup api="/exist/apps/majlis/api/search/passive?format=xml&amp;q="
5656
formURL="forms/msSimple/lookup/mutual.xhtml"
5757
elementName="passive"
5858
formName="passive"
@@ -88,7 +88,7 @@
8888
<lookup api="/exist/apps/majlis/api/search/title?format=xml&amp;q=" formURL="forms/msSimple/lookup/title.xhtml" xpath="not(parent::*:bibl)" elementName="title" formName="title" lookupLabel="Look up title"/> -->
8989
<popup formName="worksTEI" elementName="title" label="New work"/>
9090
<lookup
91-
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
91+
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
9292
formURL="forms/msSimple/lookup/bibl.xhtml"
9393
elementName="bibl"
9494
formName="bibl"
@@ -99,6 +99,7 @@
9999
/name of request - usually specifies the type of request or element to be searched.
100100
@format - xml/json/html
101101
@collection - collections to be searched, should match collections in your data directory
102+
@prefixElement - a prefix to use for the returned element e.g. 'tei', mutually exclusive with @wrapElement
102103
@wrapElement - element that will contain the search results, if different from the name of the request
103104
example the following searches all persNames, but returns results wrapped in author element for insertion into TEI record:
104105
/exist/apps/majlis/api/search/persName?format=xml&wrapElement=tei:author&q=
@@ -303,7 +304,7 @@
303304
formName="author"
304305
lookupLabel="Look up author record."/>
305306
<lookup
306-
api="/exist/apps/majlis/api/search/title?format=xml&amp;collection=works&amp;q="
307+
api="/exist/apps/majlis/api/search/title?format=xml&amp;collection=works&amp;prefixElement=tei&amp;q="
307308
formURL="forms/msSimple/lookup/title.xhtml"
308309
elementName="title"
309310
formName="title"
@@ -492,13 +493,13 @@
492493
<globalSchema src="schemas/mss-compiled.odd"/>
493494
<xmlTemplate src="templates/full-mss-template.xml"/>
494495
<lookup
495-
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;q="
496+
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;prefixElement=tei&amp;q="
496497
formURL="forms/msSimple/lookup/persName.xhtml"
497498
elementName="persName"
498499
formName="persName"
499500
lookupLabel="Look up person record."/>
500501
<lookup
501-
api="/exist/apps/majlis/api/search/placeName?format=xml&amp;collection=places&amp;q="
502+
api="/exist/apps/majlis/api/search/placeName?format=xml&amp;collection=places&amp;prefixElement=tei&amp;q="
502503
formURL="forms/msSimple/lookup/placeName.xhtml"
503504
elementName="placeName"
504505
formName="placeName"
@@ -518,7 +519,7 @@
518519
<globalSchema src="schemas/mss-compiled.odd"/>
519520
<xmlTemplate src="templates/full-mss-template.xml"/>
520521
<lookup
521-
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
522+
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
522523
formURL="forms/msSimple/lookup/bibl.xhtml"
523524
elementName="bibl"
524525
formName="bibl"
@@ -530,28 +531,28 @@
530531
formName="idno"
531532
lookupLabel="Look up manuscript record."/>
532533
<lookup
533-
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;q="
534+
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;prefixElement=tei&amp;q="
534535
formURL="forms/msSimple/lookup/persName.xhtml"
535536
elementName="persName"
536537
formName="persName"
537538
lookupLabel="Look up person record."/>
538539
<lookup
539-
api="/exist/apps/majlis/api/search/placeName?format=xml&amp;collection=places&amp;q="
540+
api="/exist/apps/majlis/api/search/placeName?format=xml&amp;collection=places&amp;prefixElement=tei&amp;q="
540541
formURL="forms/msSimple/lookup/placeName.xhtml"
541542
elementName="placeName"
542543
formName="placeName"
543544
lookupLabel="Look up place record."/>
544-
<lookup api="/exist/apps/majlis/api/search/mutual?format=xml&amp;q="
545+
<lookup api="/exist/apps/majlis/api/search/mutual?format=xml&amp;q="
545546
formURL="forms/msSimple/lookup/mutual.xhtml"
546547
elementName="mutual"
547548
formName="mutual"
548549
lookupLabel="Look up mutual relations."/>
549-
<lookup api="/exist/apps/majlis/api/search/active?format=xml&amp;q="
550+
<lookup api="/exist/apps/majlis/api/search/active?format=xml&amp;q="
550551
formURL="forms/msSimple/lookup/mutual.xhtml"
551552
elementName="active"
552553
formName="active"
553554
lookupLabel="Look up subject of relation."/>
554-
<lookup api="/exist/apps/majlis/api/search/passive?format=xml&amp;q="
555+
<lookup api="/exist/apps/majlis/api/search/passive?format=xml&amp;q="
555556
formURL="forms/msSimple/lookup/mutual.xhtml"
556557
elementName="passive"
557558
formName="passive"
@@ -648,13 +649,13 @@
648649
<globalSchema src="schemas/mss-compiled.odd"/>
649650
<xmlTemplate src="templates/full-mss-template.xml"/>
650651
<lookup
651-
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
652+
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
652653
formURL="forms/msSimple/lookup/bibl.xhtml"
653654
elementName="bibl"
654655
formName="bibl"
655656
lookupLabel="Look up bibliographic record."/>
656657
<lookup
657-
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;q="
658+
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;prefixElement=tei&amp;q="
658659
formURL="forms/msSimple/lookup/persName.xhtml"
659660
elementName="persName"
660661
formName="persName"
@@ -673,13 +674,13 @@
673674
<localSchema src="schemas/mss-manuscript-history.xml"/>
674675
<globalSchema src="schemas/mss-compiled.odd"/>
675676
<lookup
676-
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;q="
677+
api="/exist/apps/majlis/api/search/persName?format=xml&amp;collection=persons&amp;prefixElement=tei&amp;q="
677678
formURL="forms/msSimple/lookup/persName.xhtml"
678679
elementName="persName"
679680
formName="persName"
680681
lookupLabel="Look up person record."/>
681682
<lookup
682-
api="/exist/apps/majlis/api/search/placeName?format=xml&amp;collection=places&amp;q="
683+
api="/exist/apps/majlis/api/search/placeName?format=xml&amp;collection=places&amp;prefixElement=tei&amp;q="
683684
formURL="forms/msSimple/lookup/placeName.xhtml"
684685
elementName="placeName"
685686
formName="placeName"
@@ -704,7 +705,7 @@
704705
<xmlTemplate src="templates/full-mss-template.xml"/>
705706
<lookup elementName="title" suppress="true"/>
706707
<lookup
707-
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
708+
api="/exist/apps/majlis/api/search/citation?format=xml&amp;q="
708709
formURL="forms/msSimple/lookup/bibl.xhtml"
709710
elementName="bibl"
710711
formName="bibl"

0 commit comments

Comments
 (0)