Skip to content

Commit

Permalink
Add description[] #1374
Browse files Browse the repository at this point in the history
  • Loading branch information
TobiasNx committed Aug 17, 2022
1 parent a7b483c commit f98a62c
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/main/resources/alma/alma.fix
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ retain(
"almaMmsId",
"alternativeTitle[]",
"describedBy",
"description[]",
"contribution[]",
"doi[]",
"edition[]",
Expand Down
13 changes: 12 additions & 1 deletion src/main/resources/alma/fix/fields.fix
Original file line number Diff line number Diff line change
Expand Up @@ -555,13 +555,24 @@ set_array("tableOfContents[]")

do list(path: "8564?", "var":"$i")
unless exists("$i.M")
if all_match("$i.3", "^[Ii][Nn][Hh][aA][lL][tT][sS][vV].*")
if all_match("$i.3", "^[Ii][Nn][Hh][aA][lL][tT][sS][vV].*") # Inhaltsverzeichnis
copy_field("$i.3", "tableOfContents[].$append.label")
copy_field("$i.u", "tableOfContents[].$last.id")
end
end
end

set_array("description[]")

do list(path: "8564?", "var":"$i")
unless exists("$i.M")
if all_match("$i.3", "^[Ii][Nn][Hh][aA][lL][tT][sS][tT].*") # Zusätzliche Angaben
copy_field("$i.3", "description[].$append.label")
copy_field("$i.u", "description[].$last.id")
end
end
end

# TODO: hasVersion is outcommented since it needs some remodelling
# See https://github.com/hbz/lobid-resources/issues/1242
# <!--
Expand Down
4 changes: 4 additions & 0 deletions src/test/resources/alma-fix/(DE-605)HT018295975.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@
"label" : "Inhaltsverzeichnis",
"id" : "http://digitale-objekte.hbz-nrw.de/storage2/2014/11/09/file_16/5852707.pdf"
} ],
"description" : [ {
"label" : "Inhaltstext",
"id" : "http://deposit.d-nb.de/cgi-bin/dokserv?id=4685554&prov=M&dok_var=1&dok_ext=htm"
} ],
"natureOfContent" : [ {
"label" : "Bibliografie",
"id" : "http://d-nb.info/gnd/4006432-3"
Expand Down
4 changes: 4 additions & 0 deletions src/test/resources/alma-fix/(DE-605)HT018468645.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@
"id" : "http://worldcat.org/oclc/1075919546",
"label" : "OCLC Ressource"
} ],
"description" : [ {
"label" : "Inhaltstext",
"id" : "http://deposit.d-nb.de/cgi-bin/dokserv?id=4535439&prov=M&dok_var=1&dok_ext=htm"
} ],
"related" : [ {
"note" : "Erscheint auch als Druck-Ausgabe"
}, {
Expand Down
4 changes: 4 additions & 0 deletions src/test/resources/alma-fix/(DE-605)HT019631849.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@
"label" : "Inhaltsverzeichnis",
"id" : "http://digitale-objekte.hbz-nrw.de/storage2/2018/06/21/file_26/7972761.pdf"
} ],
"description" : [ {
"label" : "Inhaltstext",
"id" : "http://deposit.dnb.de/cgi-bin/dokserv?id=c575d80bb6cd4fbbbe8bf63f61eceae9&prov=M&dok_var=1&dok_ext=htm"
} ],
"subject" : [ {
"type" : [ "Keyword" ],
"source" : {
Expand Down

0 comments on commit f98a62c

Please sign in to comment.