enju_trunk_subject 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +15 -0
- data/MIT-LICENSE +20 -0
- data/README.rdoc +3 -0
- data/Rakefile +36 -0
- data/app/controllers/classification_types_controller.rb +13 -0
- data/app/controllers/classifications_controller.rb +114 -0
- data/app/controllers/subject_has_classifications_controller.rb +97 -0
- data/app/controllers/subject_heading_type_has_subjects_controller.rb +80 -0
- data/app/controllers/subject_heading_types_controller.rb +13 -0
- data/app/controllers/subject_types_controller.rb +13 -0
- data/app/controllers/subjects_controller.rb +216 -0
- data/app/controllers/work_has_subjects_controller.rb +107 -0
- data/app/models/classification.rb +89 -0
- data/app/models/classification_type.rb +20 -0
- data/app/models/enju_subject/ability.rb +55 -0
- data/app/models/subject.rb +100 -0
- data/app/models/subject_has_classification.rb +37 -0
- data/app/models/subject_heading_type.rb +21 -0
- data/app/models/subject_heading_type_has_subject.rb +22 -0
- data/app/models/subject_type.rb +20 -0
- data/app/models/work_has_subject.rb +35 -0
- data/app/views/classification_types/_form.html.erb +19 -0
- data/app/views/classification_types/edit.html.erb +13 -0
- data/app/views/classification_types/index.html.erb +45 -0
- data/app/views/classification_types/new.html.erb +12 -0
- data/app/views/classification_types/show.html.erb +30 -0
- data/app/views/classifications/_form.html.erb +27 -0
- data/app/views/classifications/edit.html.erb +13 -0
- data/app/views/classifications/index.html.erb +54 -0
- data/app/views/classifications/new.html.erb +12 -0
- data/app/views/classifications/show.html.erb +34 -0
- data/app/views/manifestations/_classification_detail.html.erb +14 -0
- data/app/views/manifestations/_subject_detail.html.erb +14 -0
- data/app/views/manifestations/_subject_facet.html.erb +18 -0
- data/app/views/manifestations/_subject_form.html.erb +21 -0
- data/app/views/subject_has_classifications/edit.html.erb +30 -0
- data/app/views/subject_has_classifications/index.html.erb +38 -0
- data/app/views/subject_has_classifications/new.html.erb +32 -0
- data/app/views/subject_has_classifications/show.html.erb +22 -0
- data/app/views/subject_heading_type_has_subjects/edit.html.erb +28 -0
- data/app/views/subject_heading_type_has_subjects/index.html.erb +30 -0
- data/app/views/subject_heading_type_has_subjects/new.html.erb +27 -0
- data/app/views/subject_heading_type_has_subjects/show.html.erb +23 -0
- data/app/views/subject_heading_types/_form.html.erb +19 -0
- data/app/views/subject_heading_types/edit.html.erb +13 -0
- data/app/views/subject_heading_types/index.html.erb +43 -0
- data/app/views/subject_heading_types/new.html.erb +12 -0
- data/app/views/subject_heading_types/show.html.erb +27 -0
- data/app/views/subject_types/_form.html.erb +19 -0
- data/app/views/subject_types/edit.html.erb +13 -0
- data/app/views/subject_types/index.html.erb +43 -0
- data/app/views/subject_types/new.html.erb +12 -0
- data/app/views/subject_types/show.html.erb +29 -0
- data/app/views/subjects/_form.html.erb +42 -0
- data/app/views/subjects/_index.html.erb +48 -0
- data/app/views/subjects/_index_classification.html.erb +57 -0
- data/app/views/subjects/_index_work.html.erb +60 -0
- data/app/views/subjects/_show_work_list.html.erb +15 -0
- data/app/views/subjects/edit.html.erb +13 -0
- data/app/views/subjects/index.atom.builder +10 -0
- data/app/views/subjects/index.html.erb +7 -0
- data/app/views/subjects/index.rss.builder +29 -0
- data/app/views/subjects/new.html.erb +12 -0
- data/app/views/subjects/show.html.erb +69 -0
- data/app/views/subjects/show.js.erb +1 -0
- data/app/views/work_has_subjects/_form.html.erb +24 -0
- data/app/views/work_has_subjects/edit.html.erb +29 -0
- data/app/views/work_has_subjects/index.html.erb +31 -0
- data/app/views/work_has_subjects/new.html.erb +42 -0
- data/app/views/work_has_subjects/show.html.erb +25 -0
- data/config/locales/translation_en.yml +35 -0
- data/config/locales/translation_ja.yml +39 -0
- data/config/routes.rb +7 -0
- data/db/fixtures/classification_types.yml +7 -0
- data/db/fixtures/subject_types.yml +28 -0
- data/db/migrate/029_create_subjects.rb +28 -0
- data/db/migrate/142_create_classifications.rb +19 -0
- data/db/migrate/144_create_classification_types.rb +16 -0
- data/db/migrate/145_create_subject_heading_types.rb +16 -0
- data/db/migrate/146_create_subject_types.rb +16 -0
- data/db/migrate/20110913120629_add_lft_and_rgt_to_classification.rb +11 -0
- data/db/migrate/20140427142354_add_classifiation_identifier_to_classification.rb +6 -0
- data/lib/enju_subject.rb +33 -0
- data/lib/enju_subject/engine.rb +8 -0
- data/lib/enju_subject/manifestation.rb +31 -0
- data/lib/enju_subject/master_model.rb +41 -0
- data/lib/enju_subject/version.rb +3 -0
- data/lib/generators/enju_subject/setup/USAGE +8 -0
- data/lib/generators/enju_subject/setup/setup_generator.rb +10 -0
- data/lib/generators/enju_subject/setup/templates/db/fixtures/classification_types.yml +13 -0
- data/lib/generators/enju_subject/setup/templates/db/fixtures/subject_heading_types.yml +39 -0
- data/lib/generators/enju_subject/setup/templates/db/fixtures/subject_types.yml +28 -0
- data/lib/tasks/enju_subject_tasks.rake +19 -0
- data/spec/controllers/classification_types_controller_spec.rb +445 -0
- data/spec/controllers/classifications_controller_spec.rb +441 -0
- data/spec/controllers/subject_heading_types_controller_spec.rb +445 -0
- data/spec/controllers/subject_types_controller_spec.rb +447 -0
- data/spec/controllers/subjects_controller_spec.rb +437 -0
- data/spec/dummy/Rakefile +7 -0
- data/spec/dummy/app/assets/javascripts/application.js +9 -0
- data/spec/dummy/app/assets/stylesheets/application.css +7 -0
- data/spec/dummy/app/controllers/application_controller.rb +47 -0
- data/spec/dummy/app/helpers/application_helper.rb +21 -0
- data/spec/dummy/app/models/ability.rb +59 -0
- data/spec/dummy/app/models/setting.rb +4 -0
- data/spec/dummy/app/models/user.rb +43 -0
- data/spec/dummy/app/views/layouts/application.html.erb +14 -0
- data/spec/dummy/config.ru +4 -0
- data/spec/dummy/config/application.rb +46 -0
- data/spec/dummy/config/application.yml +38 -0
- data/spec/dummy/config/boot.rb +10 -0
- data/spec/dummy/config/database.yml +25 -0
- data/spec/dummy/config/environment.rb +5 -0
- data/spec/dummy/config/environments/development.rb +30 -0
- data/spec/dummy/config/environments/production.rb +60 -0
- data/spec/dummy/config/environments/test.rb +39 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy/config/initializers/devise.rb +207 -0
- data/spec/dummy/config/initializers/inflections.rb +10 -0
- data/spec/dummy/config/initializers/mime_types.rb +5 -0
- data/spec/dummy/config/initializers/secret_token.rb +7 -0
- data/spec/dummy/config/initializers/session_store.rb +8 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy/config/locales/devise.en.yml +57 -0
- data/spec/dummy/config/locales/en.yml +18 -0
- data/spec/dummy/config/locales/ja.yml +18 -0
- data/spec/dummy/config/routes.rb +60 -0
- data/spec/dummy/db/fixtures/roles.yml +25 -0
- data/spec/dummy/db/migrate/001_create_agents.rb +53 -0
- data/spec/dummy/db/migrate/005_create_manifestations.rb +56 -0
- data/spec/dummy/db/migrate/006_create_items.rb +24 -0
- data/spec/dummy/db/migrate/012_create_owns.rb +12 -0
- data/spec/dummy/db/migrate/015_create_creates.rb +12 -0
- data/spec/dummy/db/migrate/047_create_produces.rb +12 -0
- data/spec/dummy/db/migrate/059_create_libraries.rb +28 -0
- data/spec/dummy/db/migrate/069_create_shelves.rb +15 -0
- data/spec/dummy/db/migrate/073_create_carrier_types.rb +11 -0
- data/spec/dummy/db/migrate/077_create_user_groups.rb +12 -0
- data/spec/dummy/db/migrate/080_create_library_groups.rb +18 -0
- data/spec/dummy/db/migrate/112_create_frequencies.rb +12 -0
- data/spec/dummy/db/migrate/117_create_form_of_works.rb +12 -0
- data/spec/dummy/db/migrate/120_create_baskets.rb +12 -0
- data/spec/dummy/db/migrate/124_create_bookstores.rb +17 -0
- data/spec/dummy/db/migrate/125_create_donates.rb +12 -0
- data/spec/dummy/db/migrate/130_create_request_status_types.rb +12 -0
- data/spec/dummy/db/migrate/131_create_request_types.rb +12 -0
- data/spec/dummy/db/migrate/20080830154109_create_realizes.rb +13 -0
- data/spec/dummy/db/migrate/20080830172106_create_exemplifies.rb +13 -0
- data/spec/dummy/db/migrate/20080905191442_create_agent_types.rb +12 -0
- data/spec/dummy/db/migrate/20081006090811_create_subscriptions.rb +17 -0
- data/spec/dummy/db/migrate/20081006093246_create_subscribes.rb +14 -0
- data/spec/dummy/db/migrate/20081023092436_create_search_engines.rb +17 -0
- data/spec/dummy/db/migrate/20081025083323_create_countries.rb +28 -0
- data/spec/dummy/db/migrate/20081025083905_create_languages.rb +23 -0
- data/spec/dummy/db/migrate/20081027150907_create_picture_files.rb +15 -0
- data/spec/dummy/db/migrate/20081028083142_create_agent_import_files.rb +22 -0
- data/spec/dummy/db/migrate/20081028083208_create_resource_import_files.rb +22 -0
- data/spec/dummy/db/migrate/20090705133942_add_attachments_picture_to_picture_file.rb +15 -0
- data/spec/dummy/db/migrate/20090705212043_add_attachments_attachment_to_manifestation.rb +15 -0
- data/spec/dummy/db/migrate/20090719201843_create_extents.rb +12 -0
- data/spec/dummy/db/migrate/20090720091106_create_medium_of_performances.rb +12 -0
- data/spec/dummy/db/migrate/20090720091429_create_content_types.rb +12 -0
- data/spec/dummy/db/migrate/20090812151902_create_agent_relationship_types.rb +12 -0
- data/spec/dummy/db/migrate/20091012101112_add_dcndl_schema.rb +27 -0
- data/spec/dummy/db/migrate/20091025080447_create_licenses.rb +12 -0
- data/spec/dummy/db/migrate/20091202124834_create_versions.rb +18 -0
- data/spec/dummy/db/migrate/20091214131723_create_series_statements.rb +13 -0
- data/spec/dummy/db/migrate/20100129142347_create_import_requests.rb +15 -0
- data/spec/dummy/db/migrate/20100211105551_add_admin_networks_to_library_group.rb +9 -0
- data/spec/dummy/db/migrate/20100223121519_rename_series_statement_title_to_original_title.rb +13 -0
- data/spec/dummy/db/migrate/20100321235924_add_series_statement_identifier_to_series_statement.rb +10 -0
- data/spec/dummy/db/migrate/20100525124311_create_manifestation_relationships.rb +13 -0
- data/spec/dummy/db/migrate/20100606073747_create_agent_relationships.rb +13 -0
- data/spec/dummy/db/migrate/20100607044753_create_manifestation_relationship_types.rb +12 -0
- data/spec/dummy/db/migrate/20100814091104_add_position_to_agent_relationship.rb +11 -0
- data/spec/dummy/db/migrate/20100925043847_create_resource_import_results.rb +15 -0
- data/spec/dummy/db/migrate/20100925074559_create_agent_import_results.rb +12 -0
- data/spec/dummy/db/migrate/20101212070145_add_acquired_at_to_item.rb +9 -0
- data/spec/dummy/db/migrate/20110222073537_add_url_to_library_group.rb +9 -0
- data/spec/dummy/db/migrate/20110301035123_add_pub_date_to_manifestation.rb +9 -0
- data/spec/dummy/db/migrate/20110301121550_add_birth_date_and_death_date_to_agent.rb +11 -0
- data/spec/dummy/db/migrate/20110425133109_add_issn_to_series_statement.rb +9 -0
- data/spec/dummy/db/migrate/20110603184217_add_edit_mode_to_resource_import_file.rb +9 -0
- data/spec/dummy/db/migrate/20110618091240_add_periodical_to_series_statement.rb +9 -0
- data/spec/dummy/db/migrate/20110619064807_add_edition_string_to_manifestation.rb +9 -0
- data/spec/dummy/db/migrate/20110620173525_add_bookstore_id_to_item.rb +11 -0
- data/spec/dummy/db/migrate/20110627034940_create_series_statement_merge_lists.rb +9 -0
- data/spec/dummy/db/migrate/20110627035057_create_series_statement_merges.rb +12 -0
- data/spec/dummy/db/migrate/20110627122938_add_number_of_day_to_notify_overdue_to_user_group.rb +13 -0
- data/spec/dummy/db/migrate/20110820131417_create_series_has_manifestations.rb +13 -0
- data/spec/dummy/db/migrate/20110916053430_rename_manifestation_number_list_to_number_string.rb +13 -0
- data/spec/dummy/db/migrate/20110916091020_add_volume_number_to_manifestation.rb +13 -0
- data/spec/dummy/db/migrate/20110916103953_add_manifestaiton_id_to_series_statement.rb +10 -0
- data/spec/dummy/db/migrate/20110918162329_add_note_to_series_statement.rb +9 -0
- data/spec/dummy/db/migrate/20111009183423_add_ndc_to_manifestation.rb +9 -0
- data/spec/dummy/db/migrate/20111124110059_create_create_types.rb +12 -0
- data/spec/dummy/db/migrate/20111124110319_create_realize_types.rb +12 -0
- data/spec/dummy/db/migrate/20111124110355_create_produce_types.rb +12 -0
- data/spec/dummy/db/migrate/20111124112131_add_create_type_to_create.rb +7 -0
- data/spec/dummy/db/migrate/20111201121844_create_roles.rb +12 -0
- data/spec/dummy/db/migrate/20111201155456_create_users.rb +8 -0
- data/spec/dummy/db/migrate/20111201155513_add_devise_to_users.rb +49 -0
- data/spec/dummy/db/migrate/20111201163718_create_user_has_roles.rb +10 -0
- data/spec/dummy/db/migrate/20120105074911_add_isil_to_library.rb +5 -0
- data/spec/dummy/db/migrate/20120125152919_add_title_subseries_transcription_to_series_statement.rb +6 -0
- data/spec/dummy/db/migrate/20120129014038_create_budget_types.rb +12 -0
- data/spec/dummy/db/migrate/20120129020544_add_budget_type_id_to_item.rb +6 -0
- data/spec/dummy/db/migrate/20120319120638_add_content_type_id_to_manifestation.rb +6 -0
- data/spec/dummy/db/migrate/20120319173203_create_accepts.rb +14 -0
- data/spec/dummy/db/migrate/20120410104851_add_year_of_publication_to_manifestation.rb +5 -0
- data/spec/dummy/db/migrate/20120413072700_add_picture_meta_to_picture_file.rb +5 -0
- data/spec/dummy/db/migrate/20120413100352_add_fingerprint_to_picture_file.rb +5 -0
- data/spec/dummy/db/migrate/20120413161340_add_fingerprint_to_resource_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20120413161403_add_fingerprint_to_agent_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20120413170705_add_error_message_to_resource_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20120413170720_add_error_message_to_agent_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20120415060308_rename_resource_import_file_imported_at_to_executed_at.rb +9 -0
- data/spec/dummy/db/migrate/20120415164821_add_attachment_meta_to_manifestation.rb +5 -0
- data/spec/dummy/db/migrate/20120418081407_add_month_of_publication_to_manifestation.rb +5 -0
- data/spec/dummy/db/migrate/20120510140958_add_closed_to_shelf.rb +5 -0
- data/spec/dummy/db/migrate/20120511072422_add_agent_identifier_to_agent.rb +6 -0
- data/spec/dummy/db/migrate/20120602141129_add_edit_mode_to_agent_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20130221154434_add_additional_attributes_to_user.rb +26 -0
- data/spec/dummy/db/migrate/20130421093852_add_periodical_to_manifestation.rb +5 -0
- data/spec/dummy/db/migrate/20130421155019_add_creator_string_to_series_statement.rb +7 -0
- data/spec/dummy/db/migrate/20130421164124_add_series_master_to_series_statement.rb +5 -0
- data/spec/dummy/db/migrate/20130506175303_create_identifier_types.rb +12 -0
- data/spec/dummy/db/migrate/20130506175834_create_identifiers.rb +15 -0
- data/spec/dummy/db/migrate/20130509185724_add_statement_of_responsibility_to_manifestation.rb +5 -0
- data/spec/dummy/db/schema.rb +901 -0
- data/spec/dummy/db/seeds.rb +32 -0
- data/spec/dummy/public/404.html +26 -0
- data/spec/dummy/public/422.html +26 -0
- data/spec/dummy/public/500.html +26 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/script/rails +6 -0
- data/spec/dummy/spec/fixtures/subjects.yml +72 -0
- data/spec/dummy/test/fixtures/user_groups.yml +13 -0
- data/spec/dummy/test/fixtures/user_has_roles.yml +9 -0
- data/spec/dummy/test/fixtures/users.yml +11 -0
- data/spec/dummy/test/unit/user_group_test.rb +7 -0
- data/spec/dummy/test/unit/user_has_role_test.rb +7 -0
- data/spec/dummy/test/unit/user_test.rb +7 -0
- data/spec/factories/classification.rb +6 -0
- data/spec/factories/classification_type.rb +5 -0
- data/spec/factories/manifestation.rb +6 -0
- data/spec/factories/subject.rb +7 -0
- data/spec/factories/subject_heading_type.rb +5 -0
- data/spec/factories/subject_heading_type_has_subject.rb +6 -0
- data/spec/factories/subject_type.rb +5 -0
- data/spec/factories/user.rb +34 -0
- data/spec/fixtures/agent_types.yml +35 -0
- data/spec/fixtures/agents.yml +143 -0
- data/spec/fixtures/carrier_types.yml +51 -0
- data/spec/fixtures/classification_types.yml +188 -0
- data/spec/fixtures/classifications.yml +118 -0
- data/spec/fixtures/languages.yml +1901 -0
- data/spec/fixtures/library_groups.yml +33 -0
- data/spec/fixtures/manifestations.yml +22 -0
- data/spec/fixtures/roles.yml +21 -0
- data/spec/fixtures/shtsv.tsv +3 -0
- data/spec/fixtures/subject_heading_types.yml +39 -0
- data/spec/fixtures/subject_types.yml +42 -0
- data/spec/fixtures/subjects.yml +80 -0
- data/spec/fixtures/user_groups.yml +25 -0
- data/spec/fixtures/user_has_roles.yml +41 -0
- data/spec/fixtures/users.yml +69 -0
- data/spec/models/classification_spec.rb +46 -0
- data/spec/models/classification_type_spec.rb +21 -0
- data/spec/models/subject_heading_type_spec.rb +21 -0
- data/spec/models/subject_spec.rb +33 -0
- data/spec/models/subject_type_spec.rb +21 -0
- data/spec/requests/subjects_spec.rb +9 -0
- data/spec/routing/subject_heading_types_routing_spec.rb +35 -0
- data/spec/routing/subject_types_routing_spec.rb +35 -0
- data/spec/routing/subjects_routing_spec.rb +35 -0
- data/spec/spec_helper.rb +45 -0
- data/spec/support/controller_macros.rb +48 -0
- data/spec/support/devise.rb +3 -0
- metadata +675 -0
@@ -0,0 +1,33 @@
|
|
1
|
+
# Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html
|
2
|
+
one:
|
3
|
+
id: 1
|
4
|
+
name: enju_library
|
5
|
+
display_name: "<%= I18n.locale %>: Enju Library"
|
6
|
+
short_name: enju
|
7
|
+
email: next-l@library.example.jp
|
8
|
+
note:
|
9
|
+
my_networks: 0.0.0.0/0
|
10
|
+
url: "http://localhost:3000/"
|
11
|
+
position: 1
|
12
|
+
login_banner: "*Next-L Enju*"
|
13
|
+
|
14
|
+
# == Schema Information
|
15
|
+
#
|
16
|
+
# Table name: library_groups
|
17
|
+
#
|
18
|
+
# id :integer not null, primary key
|
19
|
+
# name :string(255) not null
|
20
|
+
# display_name :text
|
21
|
+
# short_name :string(255) not null
|
22
|
+
# email :string(255)
|
23
|
+
# my_networks :text
|
24
|
+
# login_banner :text
|
25
|
+
# note :text
|
26
|
+
# country_id :integer
|
27
|
+
# position :integer
|
28
|
+
# created_at :datetime not null
|
29
|
+
# updated_at :datetime not null
|
30
|
+
# admin_networks :text
|
31
|
+
# url :string(255) default("http://localhost:3000/")
|
32
|
+
#
|
33
|
+
|
@@ -0,0 +1,22 @@
|
|
1
|
+
---
|
2
|
+
manifestation_00001:
|
3
|
+
language_id: 1
|
4
|
+
updated_at: 2007-11-19 16:59:00.293393 +09:00
|
5
|
+
original_title: "\xE3\x82\x88\xE3\x81\x8F\xE3\x82\x8F\xE3\x81\x8B\xE3\x82\x8B\xE6\x9C\x80\xE6\x96\xB0Web\xE3\x82\xB5\xE3\x83\xBC\xE3\x83\x93\xE3\x82\xB9\xE6\x8A\x80\xE8\xA1\x93"
|
6
|
+
id: 1
|
7
|
+
created_at: 2007-11-19 16:59:00.293393 +09:00
|
8
|
+
manifestation_00002:
|
9
|
+
language_id: 1
|
10
|
+
updated_at: 2007-11-19 16:59:01.991512 +09:00
|
11
|
+
original_title: "\xE6\x83\x85\xE5\xA0\xB1\xE9\x80\x9A\xE4\xBF\xA1\xE3\x83\x8F\xE3\x83\xB3\xE3\x83\x89\xE3\x83\x96\xE3\x83\x83\xE3\x82\xAF2005"
|
12
|
+
id: 2
|
13
|
+
created_at: 2007-11-19 16:59:01.991512 +09:00
|
14
|
+
manifestation_00003:
|
15
|
+
language_id: 1
|
16
|
+
updated_at: 2007-11-19 16:59:02.618359 +09:00
|
17
|
+
original_title: !binary |
|
18
|
+
44GT44KM44GL44KJ44Gu55Sf5ZG956eR5a2m56CU56m26ICF44Gu44Gf44KB
|
19
|
+
44Gu44OQ44Kk44Kq54m56Kix5YWl6ZaA6Kyb5bqn
|
20
|
+
|
21
|
+
id: 3
|
22
|
+
created_at: 2007-11-19 16:59:02.618359 +09:00
|
@@ -0,0 +1,21 @@
|
|
1
|
+
---
|
2
|
+
role_00001:
|
3
|
+
name: Guest
|
4
|
+
display_name: Guest
|
5
|
+
id: 1
|
6
|
+
note:
|
7
|
+
role_00002:
|
8
|
+
name: User
|
9
|
+
display_name: User
|
10
|
+
id: 2
|
11
|
+
note:
|
12
|
+
role_00003:
|
13
|
+
name: Librarian
|
14
|
+
display_name: Librarian
|
15
|
+
id: 3
|
16
|
+
note:
|
17
|
+
role_00004:
|
18
|
+
name: Administrator
|
19
|
+
display_name: Administrator
|
20
|
+
id: 4
|
21
|
+
note:
|
@@ -0,0 +1,3 @@
|
|
1
|
+
件名標目 標目よみ ID 同義語 上位語 下位語 関連語 注記 分類記号(NDLC) 分類記号(NDC9) 参照(LCSH) 参照(BSH4) 出典(BSH4) 出典 編集履歴 作成日 最終更新日
|
2
|
+
アブダビ アブダビ 00560046 アブザビ;Abu Zaby (United Arab Emirates) GE751 292.784 n81147502 アブダビ・ドバイ;Webster世界年鑑 ; NHK外国地名発音辞典 ; 世界大百科事典 1980-06-20 2010-10-05T14:19:35
|
3
|
+
アメリカ合衆国--歴史--1783-1865 アメリカガッシュウコク--レキシ--1783-1865 00560186 United States--History--1783-1865 アメリカ合衆国--歴史--1783-1809<00560185> GH88 253.04;253.05;253.06 sh85140186 大陸国家の夢 / 安武秀岳 著 1980-06-20 2010-10-15T16:32:54
|
@@ -0,0 +1,39 @@
|
|
1
|
+
---
|
2
|
+
subject_heading_type_00001:
|
3
|
+
name: unknown
|
4
|
+
display_name: unknown
|
5
|
+
updated_at: 2008-03-03 00:44:49.850140 +09:00
|
6
|
+
id: 1
|
7
|
+
note: ""
|
8
|
+
created_at: 2008-03-03 00:44:34.260739 +09:00
|
9
|
+
position: 1
|
10
|
+
subject_heading_type_00002:
|
11
|
+
name: ndlsh
|
12
|
+
display_name: NDLSH
|
13
|
+
updated_at: 2008-03-03 00:44:49.850140 +09:00
|
14
|
+
id: 2
|
15
|
+
note: ""
|
16
|
+
created_at: 2008-03-03 00:44:34.260739 +09:00
|
17
|
+
position: 2
|
18
|
+
subject_heading_type_00003:
|
19
|
+
name: bsh
|
20
|
+
display_name: BSH
|
21
|
+
updated_at: 2008-03-03 00:44:58.685360 +09:00
|
22
|
+
id: 3
|
23
|
+
note: ""
|
24
|
+
created_at: 2008-03-03 00:44:58.685360 +09:00
|
25
|
+
position: 3
|
26
|
+
|
27
|
+
# == Schema Information
|
28
|
+
#
|
29
|
+
# Table name: subject_heading_types
|
30
|
+
#
|
31
|
+
# id :integer not null, primary key
|
32
|
+
# name :string(255) not null
|
33
|
+
# display_name :text
|
34
|
+
# note :text
|
35
|
+
# position :integer
|
36
|
+
# created_at :datetime not null
|
37
|
+
# updated_at :datetime not null
|
38
|
+
#
|
39
|
+
|
@@ -0,0 +1,42 @@
|
|
1
|
+
---
|
2
|
+
subject_type_00001:
|
3
|
+
id: 1
|
4
|
+
name: Concept
|
5
|
+
display_name: Concept
|
6
|
+
note:
|
7
|
+
position: 1
|
8
|
+
|
9
|
+
subject_type_00002:
|
10
|
+
id: 2
|
11
|
+
name: Event
|
12
|
+
display_name: Event
|
13
|
+
note:
|
14
|
+
position: 2
|
15
|
+
|
16
|
+
subject_type_00003:
|
17
|
+
id: 3
|
18
|
+
name: Object
|
19
|
+
display_name: Object
|
20
|
+
note:
|
21
|
+
position: 3
|
22
|
+
|
23
|
+
subject_type_00004:
|
24
|
+
id: 4
|
25
|
+
name: Place
|
26
|
+
display_name: Place
|
27
|
+
note:
|
28
|
+
position: 4
|
29
|
+
|
30
|
+
# == Schema Information
|
31
|
+
#
|
32
|
+
# Table name: subject_types
|
33
|
+
#
|
34
|
+
# id :integer not null, primary key
|
35
|
+
# name :string(255) not null
|
36
|
+
# display_name :text
|
37
|
+
# note :text
|
38
|
+
# position :integer
|
39
|
+
# created_at :datetime not null
|
40
|
+
# updated_at :datetime not null
|
41
|
+
#
|
42
|
+
|
@@ -0,0 +1,80 @@
|
|
1
|
+
---
|
2
|
+
subject_00001:
|
3
|
+
updated_at: 2008-03-02 03:19:58.534251 +09:00
|
4
|
+
term: next-l
|
5
|
+
scope_note:
|
6
|
+
subject_type_id: 1
|
7
|
+
term_transcription: next-l
|
8
|
+
id: 1
|
9
|
+
note:
|
10
|
+
parent_id:
|
11
|
+
created_at: 2008-03-01 17:53:06.118389 +09:00
|
12
|
+
manifestation_id: 1
|
13
|
+
subject_heading_type_id: 1
|
14
|
+
subject_00002:
|
15
|
+
updated_at: 2008-03-02 03:19:57.946759 +09:00
|
16
|
+
term: test2
|
17
|
+
scope_note:
|
18
|
+
subject_type_id: 1
|
19
|
+
term_transcription: test2
|
20
|
+
id: 2
|
21
|
+
note:
|
22
|
+
parent_id:
|
23
|
+
created_at: 2008-03-01 17:50:34.658349 +09:00
|
24
|
+
subject_heading_type_id: 1
|
25
|
+
subject_00003:
|
26
|
+
updated_at: 2008-03-02 03:19:58.048475 +09:00
|
27
|
+
term: test3
|
28
|
+
scope_note:
|
29
|
+
subject_type_id: 1
|
30
|
+
term_transcription: test3
|
31
|
+
id: 3
|
32
|
+
note:
|
33
|
+
parent_id:
|
34
|
+
created_at: 2008-03-01 17:51:39.448430 +09:00
|
35
|
+
subject_heading_type_id: 2
|
36
|
+
subject_00004:
|
37
|
+
updated_at: 2008-03-02 03:19:58.048475 +09:00
|
38
|
+
term: test4
|
39
|
+
scope_note:
|
40
|
+
subject_type_id: 1
|
41
|
+
term_transcription: test4
|
42
|
+
id: 4
|
43
|
+
note:
|
44
|
+
parent_id:
|
45
|
+
created_at: 2008-03-01 17:51:39.448430 +09:00
|
46
|
+
subject_heading_type_id: 2
|
47
|
+
subject_00005:
|
48
|
+
updated_at: 2008-03-02 03:19:58.048475 +09:00
|
49
|
+
term: test5
|
50
|
+
scope_note:
|
51
|
+
subject_type_id: 1
|
52
|
+
term_transcription: test5
|
53
|
+
id: 5
|
54
|
+
note:
|
55
|
+
parent_id:
|
56
|
+
created_at: 2008-03-01 17:51:39.448430 +09:00
|
57
|
+
subject_heading_type_id: 2
|
58
|
+
|
59
|
+
# == Schema Information
|
60
|
+
#
|
61
|
+
# Table name: subjects
|
62
|
+
#
|
63
|
+
# id :integer not null, primary key
|
64
|
+
# parent_id :integer
|
65
|
+
# use_term_id :integer
|
66
|
+
# term :string(255)
|
67
|
+
# term_transcription :text
|
68
|
+
# subject_type_id :integer not null
|
69
|
+
# scope_note :text
|
70
|
+
# note :text
|
71
|
+
# required_role_id :integer default(1), not null
|
72
|
+
# lock_version :integer default(0), not null
|
73
|
+
# created_at :datetime
|
74
|
+
# updated_at :datetime
|
75
|
+
# deleted_at :datetime
|
76
|
+
# url :string(255)
|
77
|
+
# manifestation_id :integer
|
78
|
+
# subject_heading_type_id :integer
|
79
|
+
#
|
80
|
+
|
@@ -0,0 +1,25 @@
|
|
1
|
+
---
|
2
|
+
user_group_00001:
|
3
|
+
name: (not specified)
|
4
|
+
display_name: (not specified)
|
5
|
+
updated_at: 2007-12-13 21:00:51.564542 +09:00
|
6
|
+
id: 1
|
7
|
+
note: ""
|
8
|
+
created_at: 2007-12-13 21:00:01.674976 +09:00
|
9
|
+
position: 1
|
10
|
+
user_group_00002:
|
11
|
+
name: User
|
12
|
+
display_name: User
|
13
|
+
updated_at: 2007-12-23 03:14:56.836548 +09:00
|
14
|
+
id: 2
|
15
|
+
note: ""
|
16
|
+
created_at: 2007-12-23 03:14:40.173954 +09:00
|
17
|
+
position: 2
|
18
|
+
user_group_00003:
|
19
|
+
name: Faculty
|
20
|
+
display_name: Faculty
|
21
|
+
updated_at: 2007-12-23 03:15:05.134351 +09:00
|
22
|
+
id: 3
|
23
|
+
note: ""
|
24
|
+
created_at: 2007-12-23 03:15:05.126457 +09:00
|
25
|
+
position: 3
|
@@ -0,0 +1,41 @@
|
|
1
|
+
# Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html
|
2
|
+
|
3
|
+
admin:
|
4
|
+
user_id: 1
|
5
|
+
role_id: 4
|
6
|
+
|
7
|
+
librarian1:
|
8
|
+
user_id: 2
|
9
|
+
role_id: 3
|
10
|
+
|
11
|
+
user1:
|
12
|
+
user_id: 3
|
13
|
+
role_id: 2
|
14
|
+
|
15
|
+
librarian2:
|
16
|
+
user_id: 4
|
17
|
+
role_id: 3
|
18
|
+
|
19
|
+
user2:
|
20
|
+
user_id: 5
|
21
|
+
role_id: 2
|
22
|
+
|
23
|
+
user3:
|
24
|
+
user_id: 6
|
25
|
+
role_id: 2
|
26
|
+
|
27
|
+
user4:
|
28
|
+
user_id: 7
|
29
|
+
role_id: 2
|
30
|
+
|
31
|
+
# == Schema Information
|
32
|
+
#
|
33
|
+
# Table name: user_has_roles
|
34
|
+
#
|
35
|
+
# id :integer not null, primary key
|
36
|
+
# user_id :integer
|
37
|
+
# role_id :integer
|
38
|
+
# created_at :datetime
|
39
|
+
# updated_at :datetime
|
40
|
+
#
|
41
|
+
|
@@ -0,0 +1,69 @@
|
|
1
|
+
---
|
2
|
+
admin:
|
3
|
+
updated_at: 2008-05-31 13:16:30.163731 +09:00
|
4
|
+
encrypted_password: $2a$10$vHohD1WflnTIqAa8zMkF9evwAgIZRw3XuR4d3bi29M.jph/MB/AJi
|
5
|
+
user_group_id: 2
|
6
|
+
id: 1
|
7
|
+
note:
|
8
|
+
username: admin
|
9
|
+
email: tanabe@kamata.lib.teu.ac.jp
|
10
|
+
created_at: 2007-11-19 16:58:32.111941 +09:00
|
11
|
+
required_role_id: 4
|
12
|
+
librarian1:
|
13
|
+
updated_at: 2008-05-31 12:41:16.337474 +09:00
|
14
|
+
encrypted_password: $2a$10$9O2VuTccN4gHq36ARg0QReSrb1D7WrBBhZZ759RM9moHbB0W5zCzS
|
15
|
+
user_group_id: 1
|
16
|
+
id: 2
|
17
|
+
note:
|
18
|
+
username: librarian1
|
19
|
+
email: librarian1@kamata.lib.teu.ac.jp
|
20
|
+
created_at: 2007-11-19 16:58:33.172441 +09:00
|
21
|
+
required_role_id: 1
|
22
|
+
user1:
|
23
|
+
updated_at: 2008-05-31 13:02:25.101261 +09:00
|
24
|
+
encrypted_password: $2a$10$JthS59A0BNkDOoFpCXM0V.GhhffKaoWKbzpPahYp/vTFrOyM7h/uW
|
25
|
+
user_group_id: 1
|
26
|
+
id: 3
|
27
|
+
note:
|
28
|
+
username: user1
|
29
|
+
email: user1@kamata.lib.teu.ac.jp
|
30
|
+
created_at: 2007-11-19 16:58:34.637413 +09:00
|
31
|
+
required_role_id: 3
|
32
|
+
librarian2:
|
33
|
+
updated_at: 2008-05-31 12:42:23.340575 +09:00
|
34
|
+
encrypted_password: $2a$10$YmmTGrYQ1Ir6oc7wXnp.GuNeO1eYLoP3sv8wMSIrTdaGw2BPwRrpS
|
35
|
+
user_group_id: 1
|
36
|
+
id: 4
|
37
|
+
note:
|
38
|
+
username: librarian2
|
39
|
+
created_at: 2008-01-18 12:24:04.222344 +09:00
|
40
|
+
required_role_id: 1
|
41
|
+
user2:
|
42
|
+
updated_at: 2008-05-31 12:42:44.711117 +09:00
|
43
|
+
encrypted_password: $2a$10$i7UjJhLVrJM/J7qaTwW39OXw1NiwowUEbtNHVDV0sqMLjX9.UO9ca
|
44
|
+
user_group_id: 1
|
45
|
+
id: 5
|
46
|
+
note:
|
47
|
+
username: user2
|
48
|
+
created_at: 2008-01-18 13:29:06.922728 +09:00
|
49
|
+
required_role_id: 2
|
50
|
+
user3:
|
51
|
+
updated_at: 2008-05-31 13:02:25.101261 +09:00
|
52
|
+
encrypted_password: cc53de0c2d9a1a228daa9a673ec824473747e17507a6c3c4f7e5eff8821f531d4b9e23616b3ddc66fe17006b2298a556fbd567ac080e87f00f37eef8cee6c417
|
53
|
+
user_group_id: 1
|
54
|
+
id: 6
|
55
|
+
note:
|
56
|
+
username: user3
|
57
|
+
email: user3@kamata.lib.teu.ac.jp
|
58
|
+
created_at: 2007-11-19 16:58:34.637413 +09:00
|
59
|
+
required_role_id: 3
|
60
|
+
user4:
|
61
|
+
updated_at: 2008-05-31 13:02:25.101261 +09:00
|
62
|
+
encrypted_password: cc53de0c2d9a1a228daa9a673ec824473747e17507a6c3c4f7e5eff8821f531d4b9e23616b3ddc66fe17006b2298a556fbd567ac080e87f00f37eef8cee6c417
|
63
|
+
user_group_id: 1
|
64
|
+
id: 7
|
65
|
+
note:
|
66
|
+
username: user4
|
67
|
+
email: user4@kamata.lib.teu.ac.jp
|
68
|
+
created_at: 2007-11-19 16:58:34.637413 +09:00
|
69
|
+
required_role_id: 3
|
@@ -0,0 +1,46 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
require 'spec_helper'
|
3
|
+
|
4
|
+
describe Classification do
|
5
|
+
#fixtures :classification_types
|
6
|
+
#fixtures :all
|
7
|
+
fixtures :classification_types
|
8
|
+
|
9
|
+
it "引数無し" do
|
10
|
+
lambda{Classification.import_from_tsv}.should raise_error(ArgumentError)
|
11
|
+
end
|
12
|
+
|
13
|
+
it "引数あり" do
|
14
|
+
lambda{Classification.import_from_tsv("/no_file")}.should raise_error(Errno::ENOENT)
|
15
|
+
end
|
16
|
+
|
17
|
+
it "引数あり" do
|
18
|
+
path = "#{Rails.root}/../../spec/fixtures/shtsv.tsv"
|
19
|
+
Classification.import_from_tsv(path)
|
20
|
+
r = Classification.all
|
21
|
+
r.size.should == 4
|
22
|
+
r[0].classifiation_identifier = "292.784"
|
23
|
+
r[1].classifiation_identifier = "253.04"
|
24
|
+
r[2].classifiation_identifier = "253.05"
|
25
|
+
r[3].classifiation_identifier = "253.06"
|
26
|
+
end
|
27
|
+
|
28
|
+
|
29
|
+
end
|
30
|
+
|
31
|
+
# == Schema Information
|
32
|
+
#
|
33
|
+
# Table name: classifications
|
34
|
+
#
|
35
|
+
# id :integer not null, primary key
|
36
|
+
# parent_id :integer
|
37
|
+
# category :string(255) not null
|
38
|
+
# note :text
|
39
|
+
# classification_type_id :integer not null
|
40
|
+
# created_at :datetime not null
|
41
|
+
# updated_at :datetime not null
|
42
|
+
# lft :integer
|
43
|
+
# rgt :integer
|
44
|
+
# manifestation_id :integer
|
45
|
+
#
|
46
|
+
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
require 'spec_helper'
|
3
|
+
|
4
|
+
describe ClassificationType do
|
5
|
+
#pending "add some examples to (or delete) #{__FILE__}"
|
6
|
+
|
7
|
+
end
|
8
|
+
|
9
|
+
# == Schema Information
|
10
|
+
#
|
11
|
+
# Table name: classification_types
|
12
|
+
#
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
|
+
# display_name :text
|
16
|
+
# note :text
|
17
|
+
# position :integer
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
|
+
#
|
21
|
+
|