enju_seed 0.3.0.beta.1 → 0.3.0.beta.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (55) hide show
  1. checksums.yaml +4 -4
  2. data/README.rdoc +9 -1
  3. data/db/migrate/20140122054321_create_profiles.rb +6 -1
  4. data/lib/enju_seed/version.rb +1 -1
  5. data/spec/dummy/db/migrate/001_create_agents.rb +6 -6
  6. data/spec/dummy/db/migrate/005_create_manifestations.rb +12 -12
  7. data/spec/dummy/db/migrate/006_create_items.rb +5 -5
  8. data/spec/dummy/db/migrate/012_create_owns.rb +2 -2
  9. data/spec/dummy/db/migrate/015_create_creates.rb +2 -2
  10. data/spec/dummy/db/migrate/047_create_produces.rb +2 -2
  11. data/spec/dummy/db/migrate/059_create_libraries.rb +7 -7
  12. data/spec/dummy/db/migrate/069_create_shelves.rb +3 -3
  13. data/spec/dummy/db/migrate/073_create_carrier_types.rb +1 -1
  14. data/spec/dummy/db/migrate/080_create_library_groups.rb +2 -2
  15. data/spec/dummy/db/migrate/112_create_frequencies.rb +1 -1
  16. data/spec/dummy/db/migrate/117_create_form_of_works.rb +1 -1
  17. data/spec/dummy/db/migrate/120_create_baskets.rb +1 -1
  18. data/spec/dummy/db/migrate/124_create_bookstores.rb +1 -1
  19. data/spec/dummy/db/migrate/125_create_donates.rb +2 -2
  20. data/spec/dummy/db/migrate/130_create_request_status_types.rb +1 -1
  21. data/spec/dummy/db/migrate/131_create_request_types.rb +1 -1
  22. data/spec/dummy/db/migrate/133_create_agent_merges.rb +1 -1
  23. data/spec/dummy/db/migrate/20080830154109_create_realizes.rb +2 -2
  24. data/spec/dummy/db/migrate/20080830172106_create_exemplifies.rb +3 -3
  25. data/spec/dummy/db/migrate/20080905191442_create_agent_types.rb +1 -1
  26. data/spec/dummy/db/migrate/20081006090811_create_subscriptions.rb +3 -3
  27. data/spec/dummy/db/migrate/20081006093246_create_subscribes.rb +4 -4
  28. data/spec/dummy/db/migrate/20081023092436_create_search_engines.rb +5 -5
  29. data/spec/dummy/db/migrate/20081025083323_create_countries.rb +9 -8
  30. data/spec/dummy/db/migrate/20081025083905_create_languages.rb +6 -5
  31. data/spec/dummy/db/migrate/20081027150907_create_picture_files.rb +1 -1
  32. data/spec/dummy/db/migrate/20090720091106_create_medium_of_performances.rb +1 -1
  33. data/spec/dummy/db/migrate/20090720091429_create_content_types.rb +1 -1
  34. data/spec/dummy/db/migrate/20090812151902_create_agent_relationship_types.rb +1 -1
  35. data/spec/dummy/db/migrate/20091025080447_create_licenses.rb +1 -1
  36. data/spec/dummy/db/migrate/20100607044753_create_manifestation_relationship_types.rb +1 -1
  37. data/spec/dummy/db/migrate/20110222073537_add_url_to_library_group.rb +1 -1
  38. data/spec/dummy/db/migrate/20110318183304_add_valid_period_for_new_user_to_user_group.rb +1 -1
  39. data/spec/dummy/db/migrate/20110627035057_create_series_statement_merges.rb +3 -3
  40. data/spec/dummy/db/migrate/20120125152919_add_title_subseries_transcription_to_series_statement.rb +1 -0
  41. data/spec/dummy/db/migrate/20120129020544_add_budget_type_id_to_item.rb +1 -0
  42. data/spec/dummy/db/migrate/20120319120638_add_content_type_id_to_manifestation.rb +2 -1
  43. data/spec/dummy/db/migrate/20120510140958_add_closed_to_shelf.rb +1 -1
  44. data/spec/dummy/db/migrate/20130506175834_create_identifiers.rb +2 -2
  45. data/spec/dummy/db/migrate/20140519170214_create_resource_import_file_transitions.rb +5 -5
  46. data/spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb +4 -4
  47. data/spec/dummy/db/migrate/20140524020735_create_agent_import_file_transitions.rb +4 -4
  48. data/spec/dummy/db/migrate/20140614141500_create_resource_export_file_transitions.rb +5 -5
  49. data/spec/dummy/db/migrate/20160813191533_add_book_jacket_source_to_library_group.rb +5 -0
  50. data/spec/dummy/db/migrate/20160813191820_add_screenshot_generator_to_library_group.rb +5 -0
  51. data/spec/dummy/db/migrate/20161114083857_add_image_data_to_picture_file.rb +5 -0
  52. data/spec/dummy/db/migrate/20161115184747_add_attachment_data_to_user_import_file.rb +5 -0
  53. data/spec/dummy/db/migrate/20161115184756_add_attachment_data_to_user_export_file.rb +5 -0
  54. data/spec/dummy/db/schema.rb +1423 -1417
  55. metadata +264 -254
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 12d5406b47c01ad5eff1fddf96780ac07cb9811f
4
- data.tar.gz: 58e3757e3a87b1f4007c1a64b3d7d8a2fa688826
3
+ metadata.gz: 48b31d26672c8844701cfdbec37fc2675a81a78c
4
+ data.tar.gz: 7464aa8b393cce0ee2b65f25b23df7854dcbfe84
5
5
  SHA512:
6
- metadata.gz: dcf4b2c8b790217b06a9331578e168232571dc7335e4d3f0b411f81629dcf1a3f9efacc26eb0ac36748dfcdf605c2b945473a4994c9e2f2ffe37d535388af5bf
7
- data.tar.gz: a30958543f26617543bfacf25d7f04b40cca36b093fbc8cc6426ee21b5c901a6630c1114b52ccf4b9ee5535b3c215d70af4f6071b78dd614f1ccd33293ee3f6f
6
+ metadata.gz: af5c9d7deddcb3bc31ab7d907aaa9b8e8c2caee1aaef4dec4c2a18b58fab80390524358b066df1a881cba048c63f9318b206d301b1877b2f1047d8ad0e388e88
7
+ data.tar.gz: 92acef3d30732debbfb63d4829f908a670c79cf6e037eb8e30b72e444912bb4482de8fe8b3013e17902356f379c807ea2f554088845ba607a1d241ce5f33759a
data/README.rdoc CHANGED
@@ -1,3 +1,11 @@
1
1
  = EnjuSeed
2
+ {<img src="https://travis-ci.org/next-l/enju_seed.svg?branch=master" alt="Build Status" />}[https://travis-ci.org/next-l/enju_seed]
3
+ {<img src="https://codeclimate.com/github/next-l/enju_seed/badges/gpa.svg" />}[https://codeclimate.com/github/next-l/enju_seed]
4
+ {<img src="https://codeclimate.com/github/next-l/enju_seed/badges/coverage.svg" />}[https://codeclimate.com/github/next-l/enju_seed/coverage]
5
+ {<img src="https://hakiri.io/github/next-l/enju_seed/master.svg" alt="security" />}[https://hakiri.io/github/next-l/enju_seed/master]
2
6
 
3
- This project rocks and uses MIT-LICENSE.
7
+ This project rocks and uses MIT-LICENSE.
8
+
9
+ == 製作者・貢献者 (Authors and contributors)
10
+ * {TANABE, Kosuke}[https://github.com/nabeta] ({@nabeta}[https://twitter.com/nabeta])
11
+ * {Project Next-L}[http://www.next-l.jp] ({@ProjectNextL}[https://twitter.com/ProjectNextL])
@@ -1,6 +1,11 @@
1
1
  class CreateProfiles < ActiveRecord::Migration
2
2
  def change
3
- create_table :profiles do |t|
3
+ if ENV['ENJU_ID_TYPE'] == 'uuid'
4
+ options = {id: :uuid, default: 'gen_random_uuid()'}
5
+ else
6
+ options = {}
7
+ end
8
+ create_table :profiles, options do |t|
4
9
  t.references :user, index: true, foreign_key: true
5
10
  t.references :user_group, index: true
6
11
  t.references :library, index: true
@@ -1,3 +1,3 @@
1
1
  module EnjuSeed
2
- VERSION = '0.3.0.beta.1'.freeze
2
+ VERSION = '0.3.0.beta.2'.freeze
3
3
  end
@@ -32,13 +32,13 @@ class CreateAgents < ActiveRecord::Migration
32
32
  t.text :region
33
33
  t.datetime :date_of_birth
34
34
  t.datetime :date_of_death
35
- t.integer :language_id, default: 1, null: false
36
- t.integer :country_id, default: 1, null: false
37
- t.integer :agent_type_id, default: 1, null: false
38
- t.integer :lock_version, default: 0, null: false
35
+ t.integer :language_id, :default => 1, :null => false
36
+ t.integer :country_id, :default => 1, :null => false
37
+ t.integer :agent_type_id, :default => 1, :null => false
38
+ t.integer :lock_version, :default => 0, :null => false
39
39
  t.text :note
40
- t.integer :required_role_id, default: 1, null: false
41
- t.integer :required_score, default: 0, null: false
40
+ t.integer :required_role_id, :default => 1, :null => false
41
+ t.integer :required_score, :default => 0, :null => false
42
42
  t.text :email
43
43
  t.text :url
44
44
  end
@@ -1,7 +1,7 @@
1
1
  class CreateManifestations < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :manifestations do |t|
4
- t.text :original_title, null: false
4
+ t.text :original_title, :null => false
5
5
  t.text :title_alternative
6
6
  t.text :title_transcription
7
7
  t.string :classification_number
@@ -11,8 +11,8 @@ class CreateManifestations < ActiveRecord::Migration
11
11
  t.timestamps
12
12
  t.datetime :deleted_at
13
13
  t.string :access_address
14
- t.integer :language_id, default: 1, null: false
15
- t.integer :carrier_type_id, default: 1, null: false
14
+ t.integer :language_id, :default => 1, :null => false
15
+ t.integer :carrier_type_id, :default => 1, :null => false
16
16
  t.integer :start_page
17
17
  t.integer :end_page
18
18
  t.integer :height
@@ -25,17 +25,17 @@ class CreateManifestations < ActiveRecord::Migration
25
25
  t.string :serial_number_string
26
26
  t.integer :edition
27
27
  t.text :note
28
- t.boolean :repository_content, default: false, null: false
29
- t.integer :lock_version, default: 0, null: false
30
- t.integer :required_role_id, default: 1, null: false
31
- t.integer :required_score, default: 0, null: false
32
- t.integer :frequency_id, default: 1, null: false
33
- t.boolean :subscription_master, default: false, null: false
28
+ t.boolean :repository_content, :default => false, :null => false
29
+ t.integer :lock_version, :default => 0, :null => false
30
+ t.integer :required_role_id, :default => 1, :null => false
31
+ t.integer :required_score, :default => 0, :null => false
32
+ t.integer :frequency_id, :default => 1, :null => false
33
+ t.boolean :subscription_master, :default => false, :null => false
34
34
  end
35
- # add_index :manifestations, :carrier_type_id
36
- # add_index :manifestations, :required_role_id
35
+ #add_index :manifestations, :carrier_type_id
36
+ #add_index :manifestations, :required_role_id
37
37
  add_index :manifestations, :access_address
38
- # add_index :manifestations, :frequency_id
38
+ #add_index :manifestations, :frequency_id
39
39
  add_index :manifestations, :manifestation_identifier
40
40
  add_index :manifestations, :updated_at
41
41
  add_index :manifestations, :date_of_publication
@@ -5,14 +5,14 @@ class CreateItems < ActiveRecord::Migration
5
5
  t.string :item_identifier
6
6
  t.timestamps
7
7
  t.datetime :deleted_at
8
- t.integer :shelf_id, default: 1, null: false
9
- t.boolean :include_supplements, default: false, null: false
8
+ t.integer :shelf_id, :default => 1, :null => false
9
+ t.boolean :include_supplements, :default => false, :null => false
10
10
  t.text :note
11
11
  t.string :url
12
12
  t.integer :price
13
- t.integer :lock_version, default: 0, null: false
14
- t.integer :required_role_id, default: 1, null: false
15
- t.integer :required_score, default: 0, null: false
13
+ t.integer :lock_version, :default => 0, :null => false
14
+ t.integer :required_role_id, :default => 1, :null => false
15
+ t.integer :required_score, :default => 0, :null => false
16
16
  end
17
17
  add_index :items, :shelf_id
18
18
  add_index :items, :item_identifier
@@ -1,8 +1,8 @@
1
1
  class CreateOwns < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :owns do |t|
4
- t.references :agent, null: false
5
- t.references :item, null: false
4
+ t.references :agent, :null => false
5
+ t.references :item, :null => false
6
6
  t.integer :position
7
7
  t.timestamps
8
8
  end
@@ -1,8 +1,8 @@
1
1
  class CreateCreates < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :creates do |t|
4
- t.references :agent, null: false
5
- t.references :work, null: false
4
+ t.references :agent, :null => false
5
+ t.references :work, :null => false
6
6
  t.integer :position
7
7
  t.timestamps
8
8
  end
@@ -1,8 +1,8 @@
1
1
  class CreateProduces < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :produces do |t|
4
- t.references :agent, null: false
5
- t.references :manifestation, null: false
4
+ t.references :agent, :null => false
5
+ t.references :manifestation, :null => false
6
6
  t.integer :position
7
7
  t.timestamps
8
8
  end
@@ -1,9 +1,9 @@
1
1
  class CreateLibraries < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :libraries do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
- t.string :short_display_name, null: false
6
+ t.string :short_display_name, :null => false
7
7
  t.string :zip_code
8
8
  t.text :street
9
9
  t.text :locality
@@ -12,10 +12,10 @@ class CreateLibraries < ActiveRecord::Migration
12
12
  t.string :telephone_number_2
13
13
  t.string :fax_number
14
14
  t.text :note
15
- t.integer :call_number_rows, default: 1, null: false
16
- t.string :call_number_delimiter, default: '|', null: false
17
- t.integer :library_group_id, default: 1, null: false
18
- t.integer :users_count, default: 0, null: false
15
+ t.integer :call_number_rows, :default => 1, :null => false
16
+ t.string :call_number_delimiter, :default => "|", :null => false
17
+ t.integer :library_group_id, :default => 1, :null => false
18
+ t.integer :users_count, :default => 0, :null => false
19
19
  t.integer :position
20
20
  t.integer :country_id
21
21
 
@@ -23,6 +23,6 @@ class CreateLibraries < ActiveRecord::Migration
23
23
  t.datetime :deleted_at
24
24
  end
25
25
  add_index :libraries, :library_group_id
26
- add_index :libraries, :name, unique: true
26
+ add_index :libraries, :name, :unique => true
27
27
  end
28
28
  end
@@ -1,11 +1,11 @@
1
1
  class CreateShelves < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :shelves do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
7
- t.integer :library_id, default: 1, null: false
8
- t.integer :items_count, default: 0, null: false
7
+ t.integer :library_id, :default => 1, :null => false
8
+ t.integer :items_count, :default => 0, :null => false
9
9
  t.integer :position
10
10
  t.timestamps
11
11
  t.datetime :deleted_at
@@ -1,7 +1,7 @@
1
1
  class CreateCarrierTypes < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :carrier_types do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
7
7
  t.integer :position
@@ -1,9 +1,9 @@
1
1
  class CreateLibraryGroups < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :library_groups do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
- t.string :short_name, null: false
6
+ t.string :short_name, :null => false
7
7
  t.text :my_networks
8
8
  t.text :login_banner
9
9
  t.text :note
@@ -1,7 +1,7 @@
1
1
  class CreateFrequencies < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :frequencies do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
7
7
  t.integer :position
@@ -1,7 +1,7 @@
1
1
  class CreateFormOfWorks < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :form_of_works do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
7
7
  t.integer :position
@@ -3,7 +3,7 @@ class CreateBaskets < ActiveRecord::Migration
3
3
  create_table :baskets do |t|
4
4
  t.integer :user_id
5
5
  t.text :note
6
- t.integer :lock_version, default: 0, null: false
6
+ t.integer :lock_version, :default => 0, :null => false
7
7
 
8
8
  t.timestamps
9
9
  end
@@ -1,7 +1,7 @@
1
1
  class CreateBookstores < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :bookstores do |t|
4
- t.text :name, null: false
4
+ t.text :name, :null => false
5
5
  t.string :zip_code
6
6
  t.text :address
7
7
  t.text :note
@@ -1,8 +1,8 @@
1
1
  class CreateDonates < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :donates do |t|
4
- t.integer :agent_id, null: false
5
- t.integer :item_id, null: false
4
+ t.integer :agent_id, :null => false
5
+ t.integer :item_id, :null => false
6
6
 
7
7
  t.timestamps
8
8
  end
@@ -1,7 +1,7 @@
1
1
  class CreateRequestStatusTypes < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :request_status_types do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
7
7
  t.integer :position
@@ -1,7 +1,7 @@
1
1
  class CreateRequestTypes < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :request_types do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
7
7
  t.integer :position
@@ -1,7 +1,7 @@
1
1
  class CreateAgentMerges < ActiveRecord::Migration
2
2
  def self.up
3
3
  create_table :agent_merges do |t|
4
- t.integer :agent_id, :agent_merge_list_id, null: false
4
+ t.integer :agent_id, :agent_merge_list_id, :null => false
5
5
 
6
6
  t.timestamps
7
7
  end
@@ -1,8 +1,8 @@
1
1
  class CreateRealizes < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :realizes do |t|
4
- t.references :agent, null: false
5
- t.references :expression, null: false
4
+ t.references :agent, :null => false
5
+ t.references :expression, :null => false
6
6
  t.integer :position
7
7
 
8
8
  t.timestamps
@@ -1,13 +1,13 @@
1
1
  class CreateExemplifies < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :exemplifies do |t|
4
- t.integer :manifestation_id, null: false
5
- t.integer :item_id, null: false
4
+ t.integer :manifestation_id, :null => false
5
+ t.integer :item_id, :null => false
6
6
  t.integer :position
7
7
 
8
8
  t.timestamps
9
9
  end
10
10
  add_index :exemplifies, :manifestation_id
11
- add_index :exemplifies, :item_id, unique: true
11
+ add_index :exemplifies, :item_id, :unique => true
12
12
  end
13
13
  end
@@ -1,7 +1,7 @@
1
1
  class CreateAgentTypes < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :agent_types do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
7
7
  t.integer :position
@@ -1,13 +1,13 @@
1
1
  class CreateSubscriptions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :subscriptions do |t|
4
- t.text :title, null: false
4
+ t.text :title, :null => false
5
5
  t.text :note
6
- # t.integer :subscription_list_id, :integer
6
+ #t.integer :subscription_list_id, :integer
7
7
  t.integer :user_id
8
8
  t.integer :order_list_id
9
9
  t.datetime :deleted_at
10
- t.integer :subscribes_count, default: 0, null: false
10
+ t.integer :subscribes_count, :default => 0, :null => false
11
11
 
12
12
  t.timestamps
13
13
  end
@@ -1,10 +1,10 @@
1
1
  class CreateSubscribes < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :subscribes do |t|
4
- t.integer :subscription_id, null: false
5
- t.integer :work_id, null: false
6
- t.datetime :start_at, null: false
7
- t.datetime :end_at, null: false
4
+ t.integer :subscription_id, :null => false
5
+ t.integer :work_id, :null => false
6
+ t.datetime :start_at, :null => false
7
+ t.datetime :end_at, :null => false
8
8
 
9
9
  t.timestamps
10
10
  end
@@ -1,12 +1,12 @@
1
1
  class CreateSearchEngines < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :search_engines do |t|
4
- t.string :name, null: false
4
+ t.string :name, :null => false
5
5
  t.text :display_name
6
- t.string :url, null: false
7
- t.text :base_url, null: false
8
- t.text :http_method, null: false
9
- t.text :query_param, null: false
6
+ t.string :url, :null => false
7
+ t.text :base_url, :null => false
8
+ t.text :http_method, :null => false
9
+ t.text :query_param, :null => false
10
10
  t.text :additional_param
11
11
  t.text :note
12
12
  t.integer :position
@@ -1,21 +1,22 @@
1
1
  class CreateCountries < ActiveRecord::Migration
2
+
2
3
  # ISO 3166 is the International Standard for country codes.
3
4
  #
4
- # ISO 3166-1:2006 Codes for the representation of names of countries and their subdivisions - Part 1:
5
- # Country codes which is what most users know as ISO's country codes. First published in 1974, it is has since
6
- # then become one of the world's most popular and most widely used standard solution for coding country names.
7
- # It contains a two-letter code which is recommended as the general purpose code, a three-letter code which has
5
+ # ISO 3166-1:2006 Codes for the representation of names of countries and their subdivisions - Part 1:
6
+ # Country codes which is what most users know as ISO's country codes. First published in 1974, it is has since
7
+ # then become one of the world's most popular and most widely used standard solution for coding country names.
8
+ # It contains a two-letter code which is recommended as the general purpose code, a three-letter code which has
8
9
  # better mnenomic properties and a numeric-3 code which can be useful if script independence of the codes is important.
9
10
  #
10
11
  # http://www.iso.org/iso/country_codes/background_on_iso_3166/what_is_iso_3166.htm
11
12
 
12
13
  def change
13
14
  create_table :countries do |t|
14
- t.string :name, size: 80, null: false
15
+ t.string :name, :size => 80, :null => false
15
16
  t.text :display_name
16
- t.string :alpha_2, size: 2
17
- t.string :alpha_3, size: 3
18
- t.string :numeric_3, size: 3
17
+ t.string :alpha_2, :size => 2
18
+ t.string :alpha_3, :size => 3
19
+ t.string :numeric_3, :size => 3
19
20
  t.text :note
20
21
  t.integer :position
21
22
  end