Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Webapp to cope with recent schema changes #345

Merged
merged 5 commits into from
Mar 26, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
replace @classcode with @class
  • Loading branch information
peterstadler committed Mar 23, 2020
commit f9b6510731b73dd764e6e87b8a7add78ffad1d13
4 changes: 2 additions & 2 deletions modules/app.xqm
Original file line number Diff line number Diff line change
Expand Up @@ -804,7 +804,7 @@ declare
map {
'ids' : $model?doc//mei:altId[not(@type='gnd')],
'relators' : query:relators($model?doc),
'workType' : $model?doc//mei:term/data(@classcode),
'workType' : $model?doc//mei:term/data(@class),
'titles' : $print-titles($model?doc, false()),
'altTitles' : $print-titles($model?doc, true())
}
Expand Down Expand Up @@ -1779,7 +1779,7 @@ declare
'docType' : config:get-doctype-by-id($model('result-page-entry')/root()/*/data(@xml:id)),
'relators' : query:relators($model('result-page-entry')),
'biblioType' : $model('result-page-entry')/tei:biblStruct/data(@type),
'workType' : $model('result-page-entry')//mei:term/data(@classcode),
'workType' : $model('result-page-entry')//mei:term/data(@class),
'newsDate' : date:printDate($model('result-page-entry')//tei:date[parent::tei:publicationStmt], $lang, lang:get-language-string#3, $config:default-date-picture-string)
}
};
Expand Down
2 changes: 1 addition & 1 deletion modules/gl.xqm
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ declare
'docURL' : app:createUrlForDoc($doc, $lang),
'relators' : $doc//mei:fileDesc/mei:titleStmt/mei:respStmt/mei:persName[@role],
'biblioType' : $doc/tei:biblStruct/data(@type),
'workType' : $doc//mei:term/data(@classcode),
'workType' : $doc//mei:term/data(@class),
'codeSample' : $codeSample?codeSample,
'icon-src' : '$resources/img/icons/icon_' || $docType || '.png'
}
Expand Down
4 changes: 2 additions & 2 deletions modules/img.xqm
Original file line number Diff line number Diff line change
Expand Up @@ -428,8 +428,8 @@ declare %private function img:get-generic-portrait($model as map(*), $lang as xs
let $sex :=
if(config:is-org($model('docID'))) then 'org'
else if(config:is-place($model('docID'))) then 'place'
else if($model('doc')//mei:term/data(@classcode) = 'http://d-nb.info/standards/elementset/gnd#MusicalWork') then 'musicalWork'
else if(config:is-work($model('docID')) and not($model('doc')//mei:term/data(@classcode) = 'http://d-nb.info/standards/elementset/gnd#MusicalWork')) then 'otherWork'
else if($model('doc')//mei:term/data(@class) = 'http://d-nb.info/standards/elementset/gnd#MusicalWork') then 'musicalWork'
else if(config:is-work($model('docID')) and not($model('doc')//mei:term/data(@class) = 'http://d-nb.info/standards/elementset/gnd#MusicalWork')) then 'otherWork'
else $model('doc')//tei:sex/text()
return
map {
Expand Down