Skip to content

Commit bba99ca

Browse files
committed
add some rda container types for video
1 parent abc45e2 commit bba99ca

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

frontend/locales/en.yml

+7
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,10 @@ en:
22
plugins:
33
avspace:
44
label: AV Space
5+
enumerations:
6+
container_type:
7+
video_cartridge : Video Cartridge
8+
videocassette: Videocassette
9+
videodisc: Videodisc
10+
videotape_reel: Videotape Reel
11+
other: Other

migrations/001_add_container_types.rb

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
2+
# http://www.loc.gov/standards/valuelist/rdacarrier.html
3+
values = %w(video_cartridge videocassette videodisc videotape_reel other)
4+
5+
6+
Sequel.migration do
7+
8+
up do
9+
10+
enum_id = self[:enumeration].filter(:name => 'container_type').select(:id)
11+
12+
values.each do |value|
13+
id = self[:enumeration_value].insert(:enumeration_id => enum_id, :value => value, :readonly => 0)
14+
end
15+
end
16+
end
17+

0 commit comments

Comments
 (0)