enju_nii 0.1.0.pre8 → 0.1.0.pre9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/enju_nii.rb +5 -0
- data/lib/enju_nii/cinii_book.rb +1 -1
- data/lib/enju_nii/version.rb +1 -1
- data/spec/dummy/app/controllers/application_controller.rb +4 -0
- data/spec/dummy/config/application.rb +1 -1
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/db/migrate/{001_create_patrons.rb → 001_create_agents.rb} +8 -8
- data/spec/dummy/db/migrate/005_create_manifestations.rb +7 -18
- data/spec/dummy/db/migrate/012_create_owns.rb +2 -2
- data/spec/dummy/db/migrate/015_create_creates.rb +2 -2
- data/spec/dummy/db/migrate/047_create_produces.rb +2 -2
- data/spec/dummy/db/migrate/077_create_user_groups.rb +12 -0
- data/spec/dummy/db/migrate/080_create_library_groups.rb +25 -0
- data/spec/dummy/db/migrate/125_create_donates.rb +2 -2
- data/spec/dummy/db/migrate/20080830154109_create_realizes.rb +2 -2
- data/spec/dummy/db/migrate/{20080905191442_create_patron_types.rb → 20080905191442_create_agent_types.rb} +2 -2
- data/spec/dummy/db/migrate/20081028083142_create_agent_import_files.rb +22 -0
- data/spec/dummy/db/migrate/20081028083208_create_resource_import_files.rb +1 -1
- data/spec/dummy/db/migrate/{20090812151902_create_patron_relationship_types.rb → 20090812151902_create_agent_relationship_types.rb} +2 -2
- data/spec/dummy/db/migrate/20091012101112_add_dcndl_schema.rb +2 -2
- data/spec/dummy/db/migrate/20100211105551_add_admin_networks_to_library_group.rb +9 -0
- data/spec/dummy/db/migrate/20100222124420_add_allow_bookmark_external_url_to_library_group.rb +9 -0
- data/spec/dummy/db/migrate/20100606073747_create_agent_relationships.rb +13 -0
- data/spec/dummy/db/migrate/20100814091104_add_position_to_agent_relationship.rb +11 -0
- data/spec/dummy/db/migrate/20100925074559_create_agent_import_results.rb +12 -0
- data/spec/dummy/db/migrate/20110115022329_add_position_to_library_group.rb +9 -0
- data/spec/dummy/db/migrate/20110222073537_add_url_to_library_group.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/20110318183304_add_valid_period_for_new_user_to_user_group.rb +11 -0
- data/spec/dummy/db/migrate/20111020063828_remove_dsbl_from_library_group.rb +11 -0
- data/spec/dummy/db/migrate/20111201155456_create_users.rb +0 -5
- data/spec/dummy/db/migrate/20111201155513_add_devise_to_users.rb +8 -16
- data/spec/dummy/db/migrate/20120413161403_add_fingerprint_to_agent_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/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/20121116031206_add_fulltext_content_to_manifestation.rb +5 -0
- data/spec/dummy/db/migrate/20121116033446_add_doi_to_manifestation.rb +6 -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/20130429020822_add_root_manifestation_id_to_series_statement.rb +6 -0
- data/spec/dummy/db/migrate/20130504133816_add_manifestation_id_to_subject.rb +6 -0
- data/spec/dummy/db/migrate/20130504143515_add_manifestation_id_to_classification.rb +6 -0
- data/spec/dummy/db/migrate/20130504195916_add_subject_heading_type_id_to_subject.rb +5 -0
- data/spec/dummy/db/migrate/20130506175303_create_identifier_types.rb +12 -0
- data/spec/dummy/db/migrate/20130506175834_create_identifiers.rb +14 -0
- data/spec/dummy/db/migrate/20130511144310_add_manifestation_id_to_item.rb +5 -0
- data/spec/dummy/db/schema.rb +225 -210
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/fixtures/{patron_types.yml → agent_types.yml} +4 -4
- data/spec/fixtures/identifiers.yml +113 -0
- data/spec/fixtures/library_groups.yml +33 -0
- data/spec/fixtures/manifestations.yml +1883 -0
- metadata +95 -59
- data/spec/dummy/app/models/role.rb +0 -47
- data/spec/dummy/app/models/user_has_role.rb +0 -4
- data/spec/dummy/db/migrate/143_create_subject_has_classifications.rb +0 -16
- data/spec/dummy/db/migrate/20080606052544_create_work_has_subjects.rb +0 -18
- data/spec/dummy/db/migrate/20081028083142_create_patron_import_files.rb +0 -22
- data/spec/dummy/db/migrate/20090208044541_create_subject_heading_type_has_subjects.rb +0 -16
- data/spec/dummy/db/migrate/20100606073747_create_patron_relationships.rb +0 -13
- data/spec/dummy/db/migrate/20100814091104_add_position_to_patron_relationship.rb +0 -11
- data/spec/dummy/db/migrate/20100925074559_create_patron_import_results.rb +0 -12
- data/spec/dummy/db/migrate/20110301121550_add_birth_date_and_death_date_to_patron.rb +0 -11
- data/spec/dummy/db/migrate/20110425133109_add_issn_to_series_statement.rb +0 -9
- data/spec/dummy/db/migrate/20110618091240_add_periodical_to_series_statement.rb +0 -9
- data/spec/dummy/db/migrate/20110820131417_create_series_has_manifestations.rb +0 -13
- data/spec/dummy/db/migrate/20110916053430_rename_manifestation_number_list_to_number_string.rb +0 -13
- data/spec/dummy/db/migrate/20110918161853_rename_series_statement_manifestation_id_to_root_manifestation_id.rb +0 -13
- data/spec/dummy/db/migrate/20120413161403_add_fingerprint_to_patron_import_file.rb +0 -5
- data/spec/dummy/db/migrate/20120413170720_add_error_message_to_patron_import_file.rb +0 -5
- data/spec/dummy/db/migrate/20120415060308_rename_resource_import_file_imported_at_to_executed_at.rb +0 -9
- data/spec/dummy/db/migrate/20120415060323_rename_patron_import_file_imported_at_to_executed_at.rb +0 -9
- data/spec/dummy/db/migrate/20120511072422_add_patron_identifier_to_patron.rb +0 -6
- data/spec/dummy/db/migrate/20120602141129_add_edit_mode_to_patron_import_file.rb +0 -5
- data/spec/dummy/lib/master_model.rb +0 -41
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3b816114b9d3862fee169629d8f509274a4099e4
|
4
|
+
data.tar.gz: ba1fd44f9a1b59a2e1763dba450aeae043816823
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1fb5b4b0df03b962dca428354c8f9f149236cdc6bc3ff4fecbab7e789e620eec2e93847b12fd030f60c1057ccc23f00c3ddd40af59491ad07d4d8497d54b5edf
|
7
|
+
data.tar.gz: 06f07433b63baa9b207b5419982cbedb31c479daf6707af6bf3eb97d5dd949443bdb03e2dcb2793ea612fe6e619edb286dc1109642dd48deb94b1f2dd9b6be91
|
data/lib/enju_nii.rb
CHANGED
data/lib/enju_nii/cinii_book.rb
CHANGED
data/lib/enju_nii/version.rb
CHANGED
Binary file
|
@@ -1,6 +1,6 @@
|
|
1
|
-
class
|
1
|
+
class CreateAgents < ActiveRecord::Migration
|
2
2
|
def change
|
3
|
-
create_table :
|
3
|
+
create_table :agents do |t|
|
4
4
|
t.integer :user_id
|
5
5
|
t.string :last_name
|
6
6
|
t.string :middle_name
|
@@ -35,7 +35,7 @@ class CreatePatrons < ActiveRecord::Migration
|
|
35
35
|
t.datetime :date_of_death
|
36
36
|
t.integer :language_id, :default => 1, :null => false
|
37
37
|
t.integer :country_id, :default => 1, :null => false
|
38
|
-
t.integer :
|
38
|
+
t.integer :agent_type_id, :default => 1, :null => false
|
39
39
|
t.integer :lock_version, :default => 0, :null => false
|
40
40
|
t.text :note
|
41
41
|
t.integer :required_role_id, :default => 1, :null => false
|
@@ -44,10 +44,10 @@ class CreatePatrons < ActiveRecord::Migration
|
|
44
44
|
t.text :email
|
45
45
|
t.text :url
|
46
46
|
end
|
47
|
-
add_index :
|
48
|
-
add_index :
|
49
|
-
add_index :
|
50
|
-
add_index :
|
51
|
-
add_index :
|
47
|
+
add_index :agents, :user_id, :unique => true
|
48
|
+
add_index :agents, :language_id
|
49
|
+
add_index :agents, :country_id
|
50
|
+
add_index :agents, :required_role_id
|
51
|
+
add_index :agents, :full_name
|
52
52
|
end
|
53
53
|
end
|
@@ -19,18 +19,11 @@ class CreateManifestations < ActiveRecord::Migration
|
|
19
19
|
t.integer :height
|
20
20
|
t.integer :width
|
21
21
|
t.integer :depth
|
22
|
-
t.string :isbn
|
23
|
-
t.string :isbn10
|
24
|
-
t.string :wrong_isbn
|
25
|
-
t.string :nbn
|
26
|
-
t.string :lccn
|
27
|
-
t.string :oclc_number
|
28
|
-
t.string :issn
|
29
22
|
t.integer :price # TODO: 通貨単位
|
30
23
|
t.text :fulltext
|
31
|
-
t.string :
|
32
|
-
t.string :
|
33
|
-
t.string :
|
24
|
+
t.string :volume_number_string
|
25
|
+
t.string :issue_number_string
|
26
|
+
t.string :serial_number_string
|
34
27
|
t.integer :edition
|
35
28
|
t.text :note
|
36
29
|
t.boolean :repository_content, :default => false, :null => false
|
@@ -41,16 +34,12 @@ class CreateManifestations < ActiveRecord::Migration
|
|
41
34
|
t.integer :frequency_id, :default => 1, :null => false
|
42
35
|
t.boolean :subscription_master, :default => false, :null => false
|
43
36
|
end
|
44
|
-
add_index :manifestations, :carrier_type_id
|
45
|
-
add_index :manifestations, :required_role_id
|
46
|
-
add_index :manifestations, :isbn
|
47
|
-
add_index :manifestations, :nbn
|
48
|
-
add_index :manifestations, :lccn
|
49
|
-
add_index :manifestations, :oclc_number
|
50
|
-
add_index :manifestations, :issn
|
37
|
+
#add_index :manifestations, :carrier_type_id
|
38
|
+
#add_index :manifestations, :required_role_id
|
51
39
|
add_index :manifestations, :access_address
|
52
|
-
add_index :manifestations, :frequency_id
|
40
|
+
#add_index :manifestations, :frequency_id
|
53
41
|
add_index :manifestations, :manifestation_identifier
|
54
42
|
add_index :manifestations, :updated_at
|
43
|
+
add_index :manifestations, :date_of_publication
|
55
44
|
end
|
56
45
|
end
|
@@ -1,12 +1,12 @@
|
|
1
1
|
class CreateOwns < ActiveRecord::Migration
|
2
2
|
def change
|
3
3
|
create_table :owns do |t|
|
4
|
-
t.references :
|
4
|
+
t.references :agent, :null => false
|
5
5
|
t.references :item, :null => false
|
6
6
|
t.integer :position
|
7
7
|
t.timestamps
|
8
8
|
end
|
9
|
-
add_index :owns, :
|
9
|
+
add_index :owns, :agent_id
|
10
10
|
add_index :owns, :item_id
|
11
11
|
end
|
12
12
|
end
|
@@ -1,12 +1,12 @@
|
|
1
1
|
class CreateCreates < ActiveRecord::Migration
|
2
2
|
def change
|
3
3
|
create_table :creates do |t|
|
4
|
-
t.references :
|
4
|
+
t.references :agent, :null => false
|
5
5
|
t.references :work, :null => false
|
6
6
|
t.integer :position
|
7
7
|
t.timestamps
|
8
8
|
end
|
9
|
-
add_index :creates, :
|
9
|
+
add_index :creates, :agent_id
|
10
10
|
add_index :creates, :work_id
|
11
11
|
end
|
12
12
|
end
|
@@ -1,12 +1,12 @@
|
|
1
1
|
class CreateProduces < ActiveRecord::Migration
|
2
2
|
def change
|
3
3
|
create_table :produces do |t|
|
4
|
-
t.references :
|
4
|
+
t.references :agent, :null => false
|
5
5
|
t.references :manifestation, :null => false
|
6
6
|
t.integer :position
|
7
7
|
t.timestamps
|
8
8
|
end
|
9
|
-
add_index :produces, :
|
9
|
+
add_index :produces, :agent_id
|
10
10
|
add_index :produces, :manifestation_id
|
11
11
|
end
|
12
12
|
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
class CreateLibraryGroups < ActiveRecord::Migration
|
2
|
+
def self.up
|
3
|
+
create_table :library_groups do |t|
|
4
|
+
t.string :name, :null => false
|
5
|
+
t.text :display_name
|
6
|
+
t.string :short_name, :null => false
|
7
|
+
t.string :email
|
8
|
+
t.text :my_networks
|
9
|
+
t.boolean :use_dsbl, :default => false, :null => false
|
10
|
+
t.text :dsbl_list
|
11
|
+
t.text :login_banner
|
12
|
+
t.text :note
|
13
|
+
t.integer :valid_period_for_new_user, :default => 365, :null => false
|
14
|
+
t.boolean :post_to_union_catalog, :default => false, :null => false
|
15
|
+
t.integer :country_id
|
16
|
+
|
17
|
+
t.timestamps
|
18
|
+
end
|
19
|
+
add_index :library_groups, :short_name
|
20
|
+
end
|
21
|
+
|
22
|
+
def self.down
|
23
|
+
drop_table :library_groups
|
24
|
+
end
|
25
|
+
end
|
@@ -1,12 +1,12 @@
|
|
1
1
|
class CreateDonates < ActiveRecord::Migration
|
2
2
|
def change
|
3
3
|
create_table :donates do |t|
|
4
|
-
t.integer :
|
4
|
+
t.integer :agent_id, :null => false
|
5
5
|
t.integer :item_id, :null => false
|
6
6
|
|
7
7
|
t.timestamps
|
8
8
|
end
|
9
|
-
add_index :donates, :
|
9
|
+
add_index :donates, :agent_id
|
10
10
|
add_index :donates, :item_id
|
11
11
|
end
|
12
12
|
end
|
@@ -1,13 +1,13 @@
|
|
1
1
|
class CreateRealizes < ActiveRecord::Migration
|
2
2
|
def change
|
3
3
|
create_table :realizes do |t|
|
4
|
-
t.references :
|
4
|
+
t.references :agent, :null => false
|
5
5
|
t.references :expression, :null => false
|
6
6
|
t.integer :position
|
7
7
|
|
8
8
|
t.timestamps
|
9
9
|
end
|
10
|
-
add_index :realizes, :
|
10
|
+
add_index :realizes, :agent_id
|
11
11
|
add_index :realizes, :expression_id
|
12
12
|
end
|
13
13
|
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
class CreateAgentImportFiles < ActiveRecord::Migration
|
2
|
+
def change
|
3
|
+
create_table :agent_import_files do |t|
|
4
|
+
t.integer :parent_id
|
5
|
+
t.string :content_type
|
6
|
+
t.integer :size
|
7
|
+
t.integer :user_id
|
8
|
+
t.text :note
|
9
|
+
t.datetime :executed_at
|
10
|
+
t.string :state
|
11
|
+
t.string :agent_import_file_name
|
12
|
+
t.string :agent_import_content_type
|
13
|
+
t.integer :agent_import_file_size
|
14
|
+
t.datetime :agent_import_updated_at
|
15
|
+
|
16
|
+
t.timestamps
|
17
|
+
end
|
18
|
+
add_index :agent_import_files, :parent_id
|
19
|
+
add_index :agent_import_files, :user_id
|
20
|
+
add_index :agent_import_files, :state
|
21
|
+
end
|
22
|
+
end
|
@@ -1,6 +1,6 @@
|
|
1
|
-
class
|
1
|
+
class CreateAgentRelationshipTypes < ActiveRecord::Migration
|
2
2
|
def change
|
3
|
-
create_table :
|
3
|
+
create_table :agent_relationship_types do |t|
|
4
4
|
t.string :name, :null => false
|
5
5
|
t.text :display_name
|
6
6
|
t.text :note
|
@@ -1,7 +1,7 @@
|
|
1
1
|
class AddDcndlSchema < ActiveRecord::Migration
|
2
2
|
def self.up
|
3
3
|
add_column :manifestations, :title_alternative_transcription, :text
|
4
|
-
add_column :
|
4
|
+
add_column :agents, :full_name_alternative_transcription, :text
|
5
5
|
add_column :manifestations, :description, :text
|
6
6
|
add_column :manifestations, :abstract, :text
|
7
7
|
add_column :manifestations, :available_at, :timestamp
|
@@ -14,7 +14,7 @@ class AddDcndlSchema < ActiveRecord::Migration
|
|
14
14
|
|
15
15
|
def self.down
|
16
16
|
remove_column :manifestations, :title_alternative_transcription
|
17
|
-
remove_column :
|
17
|
+
remove_column :agents, :full_name_alternative_transcription
|
18
18
|
remove_column :manifestations, :description
|
19
19
|
remove_column :manifestations, :abstract
|
20
20
|
remove_column :manifestations, :available_at
|
@@ -0,0 +1,9 @@
|
|
1
|
+
class AddAllowBookmarkExternalUrlToLibraryGroup < ActiveRecord::Migration
|
2
|
+
def self.up
|
3
|
+
add_column :library_groups, :allow_bookmark_external_url, :boolean, :null => false, :default => false
|
4
|
+
end
|
5
|
+
|
6
|
+
def self.down
|
7
|
+
remove_column :library_groups, :allow_bookmark_external_url
|
8
|
+
end
|
9
|
+
end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
class CreateAgentRelationships < ActiveRecord::Migration
|
2
|
+
def change
|
3
|
+
create_table :agent_relationships do |t|
|
4
|
+
t.integer :parent_id
|
5
|
+
t.integer :child_id
|
6
|
+
t.integer :agent_relationship_type_id
|
7
|
+
|
8
|
+
t.timestamps
|
9
|
+
end
|
10
|
+
add_index :agent_relationships, :parent_id
|
11
|
+
add_index :agent_relationships, :child_id
|
12
|
+
end
|
13
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
class AddPositionToAgentRelationship < ActiveRecord::Migration
|
2
|
+
def self.up
|
3
|
+
add_column :manifestation_relationships, :position, :integer
|
4
|
+
add_column :agent_relationships, :position, :integer
|
5
|
+
end
|
6
|
+
|
7
|
+
def self.down
|
8
|
+
remove_column :agent_relationships, :position
|
9
|
+
remove_column :manifestation_relationships, :position
|
10
|
+
end
|
11
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
class AddBirthDateAndDeathDateToAgent < ActiveRecord::Migration
|
2
|
+
def self.up
|
3
|
+
add_column :agents, :birth_date, :string
|
4
|
+
add_column :agents, :death_date, :string
|
5
|
+
end
|
6
|
+
|
7
|
+
def self.down
|
8
|
+
remove_column :agents, :death_date
|
9
|
+
remove_column :agents, :birth_date
|
10
|
+
end
|
11
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
class AddValidPeriodForNewUserToUserGroup < ActiveRecord::Migration
|
2
|
+
def self.up
|
3
|
+
add_column :user_groups, :valid_period_for_new_user, :integer, :default => 0, :null => false
|
4
|
+
add_column :user_groups, :expired_at, :timestamp
|
5
|
+
end
|
6
|
+
|
7
|
+
def self.down
|
8
|
+
remove_column :user_groups, :valid_period_for_new_user
|
9
|
+
remove_column :user_groups, :expired_at
|
10
|
+
end
|
11
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
class RemoveDsblFromLibraryGroup < ActiveRecord::Migration
|
2
|
+
def up
|
3
|
+
remove_column :library_groups, :use_dsbl
|
4
|
+
remove_column :library_groups, :dsbl_list
|
5
|
+
end
|
6
|
+
|
7
|
+
def down
|
8
|
+
add_column :library_groups, :dsbl_list, :text
|
9
|
+
add_column :library_groups, :use_dsbl, :boolean
|
10
|
+
end
|
11
|
+
end
|