libis-tools 0.9.32 → 0.9.33
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/libis/tools/metadata/mappers/kuleuven.rb +51 -55
- data/lib/libis/tools/version.rb +1 -1
- data/spec/metadata/8389207.marc +22 -1
- data/spec/metadata/marc21_spec.rb +23 -4
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c32b22bd78028e1293d30915d975d512069554bd
|
4
|
+
data.tar.gz: 809de259211204db9256b6715c310767d65c17ee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1ccbb3668e98bac56777effbb0cf04f05fc38b057533946133663adcc43fa7577ffbd325603323d2b3ae2a14b7cf2d18016974d8902bd65d10c51e3d856dc366
|
7
|
+
data.tar.gz: b6e3803215de5687653e8273e287a0360a56dd96f446bf4c1d5ec6679ff641162dc2c34cbe967ecd294c9a38bc3023d349b4947f1ebb290611561f90c62d4f6b
|
@@ -148,35 +148,35 @@ module Libis
|
|
148
148
|
def marc2dc_identifier_020(xml)
|
149
149
|
# "urn:ISBN:"[MARC 020 __ $a]
|
150
150
|
each_field('020__', 'a') { |f|
|
151
|
-
xml['dc'].identifier(
|
151
|
+
xml['dc'].identifier(element(f, prefix: 'urn:ISBN:'), 'xsi:type' => 'dcterms:URI')
|
152
152
|
}
|
153
153
|
end
|
154
154
|
|
155
155
|
def marc2dc_identifier_020_9(xml)
|
156
156
|
# "urn:ISBN:"[MARC 020 9_ $a]
|
157
157
|
each_field('0209_', 'a') { |f|
|
158
|
-
xml['dc'].identifier(
|
158
|
+
xml['dc'].identifier(element(f, prefix: 'urn:ISBN:'), 'xsi:type' => 'dcterms:URI')
|
159
159
|
}
|
160
160
|
end
|
161
161
|
|
162
162
|
def marc2dc_identifier_022(xml)
|
163
163
|
# "urn:ISSN:"[MARC 022 __ $a]
|
164
164
|
each_field('022__', 'a') { |f|
|
165
|
-
xml['dc'].identifier(
|
165
|
+
xml['dc'].identifier(element(f, prefix: 'urn:ISSN:'), 'xsi:type' => 'dcterms:URI')
|
166
166
|
}
|
167
167
|
end
|
168
168
|
|
169
169
|
def marc2dc_identifier_024_2(xml)
|
170
170
|
# "urn:ISMN:"[MARC 024 2_ $a]
|
171
171
|
each_field('0242_', 'a') { |f|
|
172
|
-
xml['dc'].identifier(
|
172
|
+
xml['dc'].identifier(element(f, prefix: 'urn:ISMN:'), 'xsi:type' => 'dcterms:URI')
|
173
173
|
}
|
174
174
|
end
|
175
175
|
|
176
176
|
def marc2dc_identifier_024_3(xml)
|
177
177
|
# "urn:EAN:"[MARC 024 3_ $a]
|
178
178
|
each_field('0243_', 'a') { |f|
|
179
|
-
xml['dc'].identifier(
|
179
|
+
xml['dc'].identifier(element(f, prefix: 'urn:EAN:'), 'xsi:type' => 'dcterms:URI')
|
180
180
|
}
|
181
181
|
end
|
182
182
|
|
@@ -192,10 +192,10 @@ module Libis
|
|
192
192
|
# ALMA: 690 02 ax0 => 650 _7 ax6 $2 == 'KADOC'
|
193
193
|
all_tags('650_7', '6a') { |t|
|
194
194
|
next unless t._2 == 'KADOC'
|
195
|
-
if t._6 =~ /^\(ODIS-(PS|ORG)\)(\d)
|
196
|
-
xml['dc'].identifier(
|
197
|
-
else
|
198
|
-
|
195
|
+
if t._6 =~ /^\(ODIS-(PS|ORG)\)(\d+)$/
|
196
|
+
xml['dc'].identifier(odis_link($1, $2, CGI::escape(t._a)), 'xsi:type' => 'dcterms:URI')
|
197
|
+
# else
|
198
|
+
# xml['dc'].identifier t._a
|
199
199
|
end
|
200
200
|
}
|
201
201
|
end
|
@@ -203,7 +203,7 @@ module Libis
|
|
203
203
|
def marc2dc_identifier_856(xml)
|
204
204
|
# [MARC 856 _2 $u]
|
205
205
|
all_tags('856_2', 'uy') { |t|
|
206
|
-
xml['dc'].identifier(
|
206
|
+
xml['dc'].identifier(element(t._u, CGI::escape(t._y), join: '#'), 'xsi:type' => 'dcterms:URI')
|
207
207
|
}
|
208
208
|
end
|
209
209
|
|
@@ -486,35 +486,35 @@ module Libis
|
|
486
486
|
def marc2dc_subject_600(xml)
|
487
487
|
# [MARC 600 #0 $a] " " [MARC 600 #0 $b] " " [MARC 600 #0 $c] " " [MARC 600 #0 $d] " " [MARC 600 #0 $g]
|
488
488
|
all_tags('600#0', 'a b c d g') { |t|
|
489
|
-
xml['dc'].subject('xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
489
|
+
xml['dc'].subject(list_s(t._abcdg), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
490
490
|
}
|
491
491
|
end
|
492
492
|
|
493
493
|
def marc2dc_subject_610(xml)
|
494
494
|
# [MARC 610 #0 $a] " " [MARC 610 #0 $c] " " [MARC 610 #0 $d] " " [MARC 610 #0 $g]
|
495
495
|
all_tags('610#0', 'a c d g') { |t|
|
496
|
-
xml['dc'].subject('xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
496
|
+
xml['dc'].subject(list_s(t._acdg), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
497
497
|
}
|
498
498
|
end
|
499
499
|
|
500
500
|
def marc2dc_subject_611(xml)
|
501
501
|
# [MARC 611 #0 $a] " " [MARC 611 #0 $c] " " [MARC 611 #0 $d] " " [MARC 611 #0 $g] " " [MARC 611 #0 $n]
|
502
502
|
all_tags('611#0', 'a c d g n') { |t|
|
503
|
-
xml['dc'].subject('xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
503
|
+
xml['dc'].subject(list_s(t._acdgn), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
504
504
|
}
|
505
505
|
end
|
506
506
|
|
507
507
|
def marc2dc_subject_630(xml)
|
508
508
|
# [MARC 630 #0 $a] " " [MARC 630 #0 $f] " " [MARC 630 #0 $g] " " [MARC 630 #0 $l] " " [MARC 630 #0 $m] " " [MARC 630 #0 $n] " " [MARC 630 #0 $o] " " [MARC 630 #0 $p] " " [MARC 630 #0 $r] " " [MARC 630 #0 $s]
|
509
509
|
all_tags('630#0', 'a f g l m n o p r s') { |t|
|
510
|
-
xml['dc'].subject('xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
510
|
+
xml['dc'].subject(list_s(t._afglmnoprs), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
511
511
|
}
|
512
512
|
end
|
513
513
|
|
514
514
|
def marc2dc_subject_650_x0(xml)
|
515
515
|
# [MARC 650 #0 $a] " " [MARC 650 #0 $x] " " [MARC 650 #0 $y] " " [MARC 650 #0 $z]
|
516
516
|
all_tags('650#0', 'a x y z') { |t|
|
517
|
-
xml['dc'].subject('xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
517
|
+
xml['dc'].subject(list_s(t._axyz), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
518
518
|
}
|
519
519
|
end
|
520
520
|
|
@@ -522,7 +522,7 @@ module Libis
|
|
522
522
|
# [MARC 650 #2 $a] " " [MARC 650 #2 $x]
|
523
523
|
all_tags('650#2', 'a x') { |t|
|
524
524
|
attributes = {'xsi:type' => 'http://purl.org/dc/terms/MESH'}
|
525
|
-
xml['dc'].subject(
|
525
|
+
xml['dc'].subject(list_s(t._ax), attributes)
|
526
526
|
}
|
527
527
|
end
|
528
528
|
|
@@ -538,7 +538,7 @@ module Libis
|
|
538
538
|
all_tags('650_7', 'a x') { |t|
|
539
539
|
next unless t._2 == 'UDC'
|
540
540
|
attributes = {'xsi:type' => 'http://purl.org/dc/terms/UDC'}
|
541
|
-
xml['dc'].subject(
|
541
|
+
xml['dc'].subject(list_s(t._ax), attributes)
|
542
542
|
}
|
543
543
|
end
|
544
544
|
|
@@ -550,11 +550,11 @@ module Libis
|
|
550
550
|
# ALMA: 082 14 ax2 => 650 _7 ax4 $2 = 'DDC abridged'
|
551
551
|
all_tags('650_7', 'a x') { |t|
|
552
552
|
next unless t._2 == 'DDC abridged'
|
553
|
-
xml['dc'].subject('xsi:type' => 'http://purl.org/dc/terms/DDC', 'xml:lang' => 'en')
|
553
|
+
xml['dc'].subject(list_s(t._ax), 'xsi:type' => 'http://purl.org/dc/terms/DDC', 'xml:lang' => 'en')
|
554
554
|
}
|
555
555
|
end
|
556
556
|
|
557
|
-
def marc2dc_subject_690(
|
557
|
+
def marc2dc_subject_690(_xml)
|
558
558
|
# [MARC 690 [xx]$a]
|
559
559
|
# Set dedups the fields
|
560
560
|
# Set.new(each_field('690##', 'a')) { |f| xml['dc'].subject f }
|
@@ -582,7 +582,7 @@ module Libis
|
|
582
582
|
def marc2dc_temporal_648(xml)
|
583
583
|
# [MARC 648 #0 $a] " " [MARC 648 #0 $x] " " [MARC 648 #0 $y] " " [MARC 648 #0 $z]
|
584
584
|
all_tags('648#0', 'a x y z') { |t|
|
585
|
-
xml['dc'].temporal('xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
585
|
+
xml['dc'].temporal(list_s(t._axyz), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
586
586
|
}
|
587
587
|
end
|
588
588
|
|
@@ -725,18 +725,18 @@ module Libis
|
|
725
725
|
all_tags('52039', 'a t') { |t|
|
726
726
|
attributes = {}
|
727
727
|
attributes['xml:lang'] = taalcode(t._9) if t.subfield_array('9').size == 1
|
728
|
-
xml['dc'].abstract(
|
728
|
+
xml['dc'].abstract(element(t._ta, join: ': '), attributes)
|
729
729
|
}
|
730
730
|
end
|
731
731
|
|
732
732
|
def marc2dc_abstract_520_3__u(xml)
|
733
733
|
# [MARC 520 3_ $u]
|
734
|
-
each_field('5203_', 'u') { |f| xml['dc'].abstract('xsi:type' => 'dcterms:URI')
|
734
|
+
each_field('5203_', 'u') { |f| xml['dc'].abstract(element(f), 'xsi:type' => 'dcterms:URI') }
|
735
735
|
end
|
736
736
|
|
737
737
|
def marc2dc_abstract_520_39_u(xml)
|
738
738
|
# [MARC 520 39 $u]
|
739
|
-
each_field('52039', 'u') { |f| xml['dc'].abstract('xsi:type' => 'dcterms:URI')
|
739
|
+
each_field('52039', 'u') { |f| xml['dc'].abstract(element(f), 'xsi:type' => 'dcterms:URI') }
|
740
740
|
end
|
741
741
|
|
742
742
|
def marc2dc_tableofcontents(xml)
|
@@ -1042,14 +1042,14 @@ module Libis
|
|
1042
1042
|
each_field('955__', 'a') { |f| xml['dc'].type f }
|
1043
1043
|
end
|
1044
1044
|
|
1045
|
-
def marc2dc_type_655_9x_a(
|
1045
|
+
def marc2dc_type_655_9x_a(_xml)
|
1046
1046
|
# [MARC 655 9# $a]
|
1047
1047
|
# each_field('6559#', 'a') { |f| xml['dc'].type f }
|
1048
1048
|
# ALMA: 655 9_ a => 955 __ b
|
1049
1049
|
# Zie marc2dc_type_655_9__a
|
1050
1050
|
end
|
1051
1051
|
|
1052
|
-
def marc2dc_type_655__4_z(
|
1052
|
+
def marc2dc_type_655__4_z(_xml)
|
1053
1053
|
# [MARC 655 _4 $z]
|
1054
1054
|
# each_field('655_4', 'z') { |f| xml['dc'].type f }
|
1055
1055
|
# ALMA: 655 _4 axyz => 653 _6 a [$xyz skipped]
|
@@ -1060,7 +1060,7 @@ module Libis
|
|
1060
1060
|
all_tags('FMT') { |t| xml['dc'].type fmt(t.datas) }
|
1061
1061
|
end
|
1062
1062
|
|
1063
|
-
def marc2dc_type_655_94_z(
|
1063
|
+
def marc2dc_type_655_94_z(_xml)
|
1064
1064
|
# [MARC 655 94 $z]
|
1065
1065
|
# each_field('65594', 'z') { |f| xml['dc'].type f }
|
1066
1066
|
# ALMA: 655 94 axyz => 653 _6 a [$xyz skipped]
|
@@ -1081,7 +1081,7 @@ module Libis
|
|
1081
1081
|
each_field('340__', 'd') { |f| xml['dc'].type f } if all_fields('340__', 'a').empty?
|
1082
1082
|
end
|
1083
1083
|
|
1084
|
-
def marc2dc_type_088____z(
|
1084
|
+
def marc2dc_type_088____z(_xml)
|
1085
1085
|
# [MARC 088 __ $z]
|
1086
1086
|
# each_field('088__', 'z') { |f| xml['dc'].type f }
|
1087
1087
|
# ALMA: 088 __ axyz9 => 340 __ a3 [$xyz skipped]
|
@@ -1091,54 +1091,54 @@ module Libis
|
|
1091
1091
|
# [MARC 088 __ $a]
|
1092
1092
|
# each_field('088__', 'a') { |f| xml['dc'].type('xml:lang' => 'en').text f }
|
1093
1093
|
# ALMA: 088 __ axyz9 => 340 __ a3 [$xyz skipped]
|
1094
|
-
each_field('340__', 'a') { |f| xml['dc'].type('xml:lang' => 'en')
|
1094
|
+
each_field('340__', 'a') { |f| xml['dc'].type(f, 'xml:lang' => 'en') }
|
1095
1095
|
end
|
1096
1096
|
|
1097
1097
|
def marc2dc_type_655__4_a(xml)
|
1098
1098
|
# [MARC 655 _4 $a]
|
1099
1099
|
# each_field('655_4', 'a') { |f| xml['dc'].type('xml:lang' => 'en').text f }
|
1100
1100
|
# ALMA: 655 _4 axyz => 653 _6 a [$xyz skipped]
|
1101
|
-
each_field('653_6', 'a') { |f| xml['dc'].type('xml:lang' => 'en')
|
1101
|
+
each_field('653_6', 'a') { |f| xml['dc'].type(f, 'xml:lang' => 'en') }
|
1102
1102
|
end
|
1103
1103
|
|
1104
|
-
def marc2dc_type_655_94_a(
|
1104
|
+
def marc2dc_type_655_94_a(_xml)
|
1105
1105
|
# [MARC 655 94 $a]
|
1106
1106
|
# each_field('65594', 'a') { |f| xml['dc'].type('xml:lang' => 'en').text f }
|
1107
1107
|
# ALMA: 655 94 axyz => 635 _6 a [$xyz skipped]
|
1108
1108
|
# Case covered by marc2dc_type_655__4_a
|
1109
1109
|
end
|
1110
1110
|
|
1111
|
-
def marc2dc_type_088____x(
|
1111
|
+
def marc2dc_type_088____x(_xml)
|
1112
1112
|
# [MARC 088 __ $x]
|
1113
1113
|
# each_field('088__', 'x') { |f| xml['dc'].type('xml:lang' => 'nl').text f }
|
1114
1114
|
# ALMA: 088 __ axyz9 => 340 __ a3 [$xyz skipped]
|
1115
1115
|
end
|
1116
1116
|
|
1117
|
-
def marc2dc_type_655__4_x(
|
1117
|
+
def marc2dc_type_655__4_x(_xml)
|
1118
1118
|
# [MARC 655 _4 $x]
|
1119
1119
|
# each_field('655_4', 'x') { |f| xml['dc'].type('xml:lang' => 'nl').text f }
|
1120
1120
|
# ALMA: 655 _4 axyz => 653 _6 a [$xyz skipped]
|
1121
1121
|
end
|
1122
1122
|
|
1123
|
-
def marc2dc_type_655_94_x(
|
1123
|
+
def marc2dc_type_655_94_x(_xml)
|
1124
1124
|
# [MARC 655 94 $x]
|
1125
1125
|
# each_field('65594', 'x') { |f| xml['dc'].type('xml:lang' => 'nl').text f }
|
1126
1126
|
# ALMA: 655 94 axyz => 653 _6 a [$xyz skipped]
|
1127
1127
|
end
|
1128
1128
|
|
1129
|
-
def marc2dc_type_088____y(
|
1129
|
+
def marc2dc_type_088____y(_xml)
|
1130
1130
|
# [MARC 088 __ $y]
|
1131
1131
|
# each_field('088__', 'y') { |f| xml['dc'].type('xml:lang' => 'fr').text f }
|
1132
1132
|
# ALMA: 088 __ axyz9 => 340 __ a3 [$xyz skipped]
|
1133
1133
|
end
|
1134
1134
|
|
1135
|
-
def marc2dc_type_655__4_y(
|
1135
|
+
def marc2dc_type_655__4_y(_xml)
|
1136
1136
|
# [MARC 655 _4 $y]
|
1137
1137
|
# each_field('655_4', 'y') { |f| xml['dc'].type('xml:lang' => 'fr').text f }
|
1138
1138
|
# ALMA: 655 _4 axyz => 653 _6 a [$xyz skipped]
|
1139
1139
|
end
|
1140
1140
|
|
1141
|
-
def marc2dc_type_655_94_y(
|
1141
|
+
def marc2dc_type_655_94_y(_xml)
|
1142
1142
|
# [MARC 655 94 $y]
|
1143
1143
|
# each_field('65594', 'y') { |f| xml['dc'].type('xml:lang' => 'fr').text f }
|
1144
1144
|
# ALMA: 655 94 axyz => 653 _6 a [$xyz skipped]
|
@@ -1147,9 +1147,7 @@ module Libis
|
|
1147
1147
|
def marc2dc_type_655__2(xml)
|
1148
1148
|
# [MARC 655 #2 $a] " " [MARC 655 #2 $x*] " " [MARC 655 #2 $9]
|
1149
1149
|
all_tags('655#2', 'a x 9') { |t|
|
1150
|
-
xml['dc'].type(
|
1151
|
-
repeat(t.a_x),
|
1152
|
-
t._9)
|
1150
|
+
xml['dc'].type(list_s(t._a, repeat(t.a_x), t._9), 'xsi:type' => 'http://purl.org/dc/terms/MESH')
|
1153
1151
|
}
|
1154
1152
|
end
|
1155
1153
|
|
@@ -1204,17 +1202,14 @@ module Libis
|
|
1204
1202
|
def marc2dc_spatial_651__0(xml)
|
1205
1203
|
# [MARC 651 #0 $a] " " [MARC 651 #0 $x*] " " [MARC 651 #0 $y] " " [MARC 651 #0 $z]
|
1206
1204
|
all_tags('651#0', 'a x y z') { |t|
|
1207
|
-
xml['dcterms'].spatial(
|
1208
|
-
repeat(t.a_x),
|
1209
|
-
t._yz)
|
1205
|
+
xml['dcterms'].spatial(list_s(t._a, repeat(t.a_x), t._yz), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
1210
1206
|
}
|
1211
1207
|
end
|
1212
1208
|
|
1213
1209
|
def marc2dc_spatial_651__2(xml)
|
1214
1210
|
# [MARC 651 #2 $a] " " [MARC 651 #2 $x*]
|
1215
1211
|
all_tags('651#2', 'a x') { |t|
|
1216
|
-
xml['dcterms'].spatial(
|
1217
|
-
repeat(t.a_x))
|
1212
|
+
xml['dcterms'].spatial(list_s(t._a, repeat(t.a_x)), 'xsi:type' => 'http://purl.org/dc/terms/LCSH')
|
1218
1213
|
}
|
1219
1214
|
end
|
1220
1215
|
|
@@ -1270,7 +1265,7 @@ module Libis
|
|
1270
1265
|
all_tags('306__', 'a') { |t| xml['dcterms'].extent repeat(t.a_a.collect { |y| y.scan(/(\d\d)(\d\d)(\d\d)/).join(':') }) }
|
1271
1266
|
end
|
1272
1267
|
|
1273
|
-
def marc2dc_extent_309(
|
1268
|
+
def marc2dc_extent_309(_xml)
|
1274
1269
|
# [MARC 309 __ $a]
|
1275
1270
|
# each_field('309__', 'a') { |f| xml['dcterms'].extent f }
|
1276
1271
|
# ALMA: 309 __ a => 306 __ a
|
@@ -1317,7 +1312,7 @@ module Libis
|
|
1317
1312
|
each_field('340__', 'e') { |f| xml['dcterms'].medium f }
|
1318
1313
|
end
|
1319
1314
|
|
1320
|
-
def marc2dc_medium_319_9(
|
1315
|
+
def marc2dc_medium_319_9(_xml)
|
1321
1316
|
# [MARC 319 9_ $a] " (" [MARC 319 9_ $9] ")"
|
1322
1317
|
# all_tags('3199_', 'a 9') { |t|
|
1323
1318
|
# xml['dcterms'].medium list_s(t._a,
|
@@ -1395,25 +1390,27 @@ module Libis
|
|
1395
1390
|
def marc2dc_source_856__1(xml)
|
1396
1391
|
# [MARC 856 _1 $u]
|
1397
1392
|
all_tags('856_1', 'uy') { |t|
|
1398
|
-
xml['dc'].source(
|
1399
|
-
|
1400
|
-
|
1393
|
+
xml['dc'].source(element(t._u,
|
1394
|
+
repeat(t.a_y.collect { |y| CGI::escape(y) }),
|
1395
|
+
join: '#'),
|
1396
|
+
'xsi:type' => 'dcterms:URI')
|
1401
1397
|
}
|
1402
1398
|
end
|
1403
1399
|
|
1404
1400
|
def marc2dc_source_856__2(xml)
|
1405
1401
|
# [MARC 856 _2 $u]
|
1406
1402
|
all_tags('856_2', 'uy') { |t|
|
1407
|
-
xml['dc'].source(
|
1408
|
-
|
1409
|
-
|
1403
|
+
xml['dc'].source(element(t._u,
|
1404
|
+
repeat(t.a_y.collect { |y| CGI::escape(y) }),
|
1405
|
+
join: '#'),
|
1406
|
+
'xsi:type' => 'dcterms:URI')
|
1410
1407
|
}
|
1411
1408
|
end
|
1412
1409
|
|
1413
1410
|
def marc2dc_source_856_4(xml)
|
1414
1411
|
# [MARC 856 40 $u]
|
1415
1412
|
all_tags('85640', 'u') { |t|
|
1416
|
-
xml['dc'].source('xsi:type' => 'dcterms:URI')
|
1413
|
+
xml['dc'].source(element(t._u), 'xsi:type' => 'dcterms:URI')
|
1417
1414
|
}
|
1418
1415
|
end
|
1419
1416
|
|
@@ -1613,9 +1610,8 @@ module Libis
|
|
1613
1610
|
all_tags('650_7', '26a') { |t|
|
1614
1611
|
next unless t._2 == 'KADOC' and t._6 =~ /^\(ODIS-(GEO)\)(\d)+$/
|
1615
1612
|
# xml['dc'].identifier('xsi:type' => 'dcterms:URI').text odis_link($1, $2, CGI::escape(t._a))
|
1616
|
-
xml['dc'].coverage list_s(t._a, element(
|
1613
|
+
xml['dc'].coverage list_s(t._a, element(t._6, prefix: '[', postfix: ']'))
|
1617
1614
|
}
|
1618
|
-
|
1619
1615
|
end
|
1620
1616
|
|
1621
1617
|
protected
|
data/lib/libis/tools/version.rb
CHANGED
data/spec/metadata/8389207.marc
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
xmlns="http://www.loc.gov/MARC21/slim" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
4
4
|
<leader>01068nam 2200241u 4500</leader>
|
5
5
|
<controlfield tag="005">20150701153710.0</controlfield>
|
6
|
-
<controlfield tag="008">000608m17221724xx |||| |
|
6
|
+
<controlfield tag="008">000608m17221724xx |||| | 000|0 lat c</controlfield>
|
7
7
|
<controlfield tag="001">9921543960101471</controlfield>
|
8
8
|
<datafield tag="035" ind1=" " ind2=" ">
|
9
9
|
<subfield code="a">(BeLVLBS)002154396LBS01-Aleph</subfield>
|
@@ -49,6 +49,27 @@
|
|
49
49
|
<subfield code="a">276 =75</subfield>
|
50
50
|
<subfield code="x">Griekse patrologie</subfield>
|
51
51
|
</datafield>
|
52
|
+
<datafield tag="650" ind1=" " ind2="7">
|
53
|
+
<subfield code="2">KADOC</subfield>
|
54
|
+
<subfield code="a">Bisdom Antwerpen (1961-heden)</subfield>
|
55
|
+
<subfield code="6">(ODIS-ORG)9284</subfield>
|
56
|
+
</datafield>
|
57
|
+
<datafield tag="650" ind1=" " ind2="7">
|
58
|
+
<subfield code="2">KADOC</subfield>
|
59
|
+
<subfield code="a">Studiecentrum voor Zielzorg en Predicatie</subfield>
|
60
|
+
<subfield code="6">(ODIS-ORG)24894</subfield>
|
61
|
+
</datafield>
|
62
|
+
<datafield tag="650" ind1=" " ind2="7">
|
63
|
+
<subfield code="2">KADOC</subfield>
|
64
|
+
<subfield code="a">Antwerpen [deelgemeente in gemeente Antwerpen - BE]</subfield>
|
65
|
+
<subfield code="6">(ODIS-GEO)10560000006504</subfield>
|
66
|
+
</datafield>
|
67
|
+
<datafield tag="650" ind1=" " ind2="7">
|
68
|
+
<subfield code="2">KADOC</subfield>
|
69
|
+
<subfield code="a">C1</subfield>
|
70
|
+
<subfield code="x">Kerken en religie</subfield>
|
71
|
+
<subfield code="6">(ODIS-HT)</subfield>
|
72
|
+
</datafield>
|
52
73
|
<datafield tag="653" ind1=" " ind2="6">
|
53
74
|
<subfield code="a">Books before 1840</subfield>
|
54
75
|
</datafield>
|
@@ -19,7 +19,7 @@ describe 'Marc21Record' do
|
|
19
19
|
expect(record.marc_dump).to eq <<-STR.align_left
|
20
20
|
LDR:'01068nam 2200241u 4500'
|
21
21
|
005:'20150701153710.0'
|
22
|
-
008:'000608m17221724xx |||| |
|
22
|
+
008:'000608m17221724xx |||| | 000|0 lat c'
|
23
23
|
001:'9921543960101471'
|
24
24
|
035: : :
|
25
25
|
\ta:["(BeLVLBS)002154396LBS01-Aleph"]
|
@@ -51,6 +51,23 @@ describe 'Marc21Record' do
|
|
51
51
|
\t2:["UDC"]
|
52
52
|
\ta:["276 =75"]
|
53
53
|
\tx:["Griekse patrologie"]
|
54
|
+
650: :7:
|
55
|
+
\t2:["KADOC"]
|
56
|
+
\ta:["Bisdom Antwerpen (1961-heden)"]
|
57
|
+
\t6:["(ODIS-ORG)9284"]
|
58
|
+
650: :7:
|
59
|
+
\t2:["KADOC"]
|
60
|
+
\ta:["Studiecentrum voor Zielzorg en Predicatie"]
|
61
|
+
\t6:["(ODIS-ORG)24894"]
|
62
|
+
650: :7:
|
63
|
+
\t2:["KADOC"]
|
64
|
+
\ta:["Antwerpen [deelgemeente in gemeente Antwerpen - BE]"]
|
65
|
+
\t6:["(ODIS-GEO)10560000006504"]
|
66
|
+
650: :7:
|
67
|
+
\t2:["KADOC"]
|
68
|
+
\ta:["C1"]
|
69
|
+
\tx:["Kerken en religie"]
|
70
|
+
\t6:["(ODIS-HT)"]
|
54
71
|
653: :6:
|
55
72
|
\ta:["Books before 1840"]
|
56
73
|
700:1: :
|
@@ -97,18 +114,20 @@ describe 'Marc21Record' do
|
|
97
114
|
<dc:identifier>urn:ControlNumber:9921543960101471</dc:identifier>
|
98
115
|
<dc:identifier>(BeLVLBS)002154396LBS01-Aleph</dc:identifier>
|
99
116
|
<dc:identifier>8389207</dc:identifier>
|
117
|
+
<dc:identifier xsi:type="dcterms:URI">http://www.odis.be/lnk/or_9284#Bisdom+Antwerpen+%281961-heden%29</dc:identifier>
|
118
|
+
<dc:identifier xsi:type="dcterms:URI">http://www.odis.be/lnk/or_24894#Studiecentrum+voor+Zielzorg+en+Predicatie</dc:identifier>
|
100
119
|
<dc:title>Anecdota Graeca, sacra et profana /</dc:title>
|
101
120
|
<dc:creator>Wolf, Johann Christoph, 1683-1739, (author)</dc:creator>
|
102
|
-
<dc:subject xsi:type="http://purl.org/dc/terms/UDC"
|
121
|
+
<dc:subject xsi:type="http://purl.org/dc/terms/UDC">276 =75 Griekse patrologie</dc:subject>
|
103
122
|
<dc:temporal>1701-1750</dc:temporal>
|
104
123
|
<dc:description>Ded. Petrus Theodorus Seelmann; Erdmannus Neumeister; Thomas Claussen; Joannes Grammius\n \nElk deel heeft eigen titelp. in roodzwartdruk, met drukkersmerk</dc:description>
|
105
124
|
<dc:date>1722 - 1724</dc:date>
|
106
|
-
<dc:type xml:lang="en"
|
125
|
+
<dc:type xml:lang="en">Books before 1840</dc:type>
|
107
126
|
<dcterms:extent>8o: 4 v.; [22], 298, [8]; [16], 354, [1]; [16], 299, [7]; [16], 271, [5] p.</dcterms:extent>
|
108
127
|
<dc:language>la</dc:language>
|
128
|
+
<dc:coverage>Antwerpen [deelgemeente in gemeente Antwerpen - BE] [(ODIS-GEO)10560000006504]</dc:coverage>
|
109
129
|
</dc:record>
|
110
130
|
STR
|
111
|
-
expect(record.to_dc.root).to be_equivalent_to(xml_doc.root).respecting_element_order
|
112
131
|
record.to_dc.root.elements.each_with_index do |element, i|
|
113
132
|
expect(element).to be_equivalent_to(xml_doc.root.elements[i])
|
114
133
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: libis-tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.33
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kris Dekeyser
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-04-
|
11
|
+
date: 2016-04-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|