enju_biblio 0.1.0.pre63 → 0.1.0.pre64

Sign up to get free protection for your applications and to get access to all the features.
Files changed (144) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/agent_import_files_controller.rb +9 -2
  3. data/app/controllers/agent_import_results_controller.rb +7 -0
  4. data/app/controllers/agent_merge_lists_controller.rb +7 -2
  5. data/app/controllers/agent_merges_controller.rb +7 -2
  6. data/app/controllers/agent_relationship_types_controller.rb +9 -4
  7. data/app/controllers/agent_relationships_controller.rb +8 -2
  8. data/app/controllers/agent_types_controller.rb +9 -4
  9. data/app/controllers/agents_controller.rb +15 -10
  10. data/app/controllers/carrier_types_controller.rb +14 -2
  11. data/app/controllers/content_types_controller.rb +9 -4
  12. data/app/controllers/countries_controller.rb +11 -4
  13. data/app/controllers/create_types_controller.rb +9 -4
  14. data/app/controllers/creates_controller.rb +8 -2
  15. data/app/controllers/donates_controller.rb +7 -2
  16. data/app/controllers/form_of_works_controller.rb +9 -4
  17. data/app/controllers/frequencies_controller.rb +9 -4
  18. data/app/controllers/identifier_types_controller.rb +11 -4
  19. data/app/controllers/import_requests_controller.rb +15 -2
  20. data/app/controllers/items_controller.rb +21 -3
  21. data/app/controllers/languages_controller.rb +12 -4
  22. data/app/controllers/licenses_controller.rb +9 -4
  23. data/app/controllers/manifestation_relationship_types_controller.rb +11 -4
  24. data/app/controllers/manifestation_relationships_controller.rb +8 -2
  25. data/app/controllers/manifestations_controller.rb +105 -10
  26. data/app/controllers/medium_of_performances_controller.rb +9 -4
  27. data/app/controllers/owns_controller.rb +7 -2
  28. data/app/controllers/picture_files_controller.rb +8 -2
  29. data/app/controllers/produce_types_controller.rb +9 -4
  30. data/app/controllers/produces_controller.rb +8 -2
  31. data/app/controllers/realize_types_controller.rb +11 -4
  32. data/app/controllers/realizes_controller.rb +8 -2
  33. data/app/controllers/resource_export_files_controller.rb +7 -2
  34. data/app/controllers/resource_import_files_controller.rb +9 -2
  35. data/app/controllers/resource_import_results_controller.rb +7 -0
  36. data/app/controllers/series_statement_merge_lists_controller.rb +7 -2
  37. data/app/controllers/series_statement_merges_controller.rb +9 -2
  38. data/app/controllers/series_statements_controller.rb +13 -2
  39. data/app/models/agent.rb +0 -9
  40. data/app/models/agent_import_file.rb +3 -3
  41. data/app/models/agent_import_file_transition.rb +1 -1
  42. data/app/models/agent_import_result.rb +0 -1
  43. data/app/models/agent_merge.rb +0 -1
  44. data/app/models/agent_merge_list.rb +0 -1
  45. data/app/models/agent_relationship.rb +0 -1
  46. data/app/models/agent_relationship_type.rb +0 -1
  47. data/app/models/agent_type.rb +0 -1
  48. data/app/models/carrier_type.rb +1 -7
  49. data/app/models/content_type.rb +0 -1
  50. data/app/models/country.rb +0 -1
  51. data/app/models/create.rb +0 -1
  52. data/app/models/create_type.rb +0 -1
  53. data/app/models/donate.rb +0 -1
  54. data/app/models/enju_biblio/ability.rb +25 -2
  55. data/app/models/exemplify.rb +1 -1
  56. data/app/models/form_of_work.rb +0 -1
  57. data/app/models/frequency.rb +0 -1
  58. data/app/models/identifier.rb +1 -1
  59. data/app/models/identifier_type.rb +0 -1
  60. data/app/models/import_request.rb +8 -7
  61. data/app/models/import_request_transition.rb +1 -1
  62. data/app/models/item.rb +0 -5
  63. data/app/models/language.rb +0 -2
  64. data/app/models/license.rb +0 -1
  65. data/app/models/manifestation.rb +29 -33
  66. data/app/models/manifestation_relationship.rb +0 -1
  67. data/app/models/manifestation_relationship_type.rb +0 -1
  68. data/app/models/medium_of_performance.rb +0 -1
  69. data/app/models/own.rb +0 -1
  70. data/app/models/picture_file.rb +1 -3
  71. data/app/models/produce.rb +0 -1
  72. data/app/models/produce_type.rb +0 -1
  73. data/app/models/realize.rb +0 -1
  74. data/app/models/realize_type.rb +0 -1
  75. data/app/models/resource_export_file.rb +9 -3
  76. data/app/models/resource_export_file_transition.rb +1 -1
  77. data/app/models/resource_import_file.rb +18 -10
  78. data/app/models/resource_import_file_transition.rb +1 -1
  79. data/app/models/resource_import_result.rb +0 -1
  80. data/app/models/series_statement.rb +0 -7
  81. data/app/models/series_statement_merge.rb +0 -1
  82. data/app/models/series_statement_merge_list.rb +0 -1
  83. data/app/views/items/index.html.erb +11 -0
  84. data/app/views/layouts/items.html.erb +29 -0
  85. data/app/views/manifestations/_form.html.erb +3 -3
  86. data/app/views/manifestations/_index_form_series_statement.html.erb +1 -1
  87. data/app/views/manifestations/_list.html.erb +15 -0
  88. data/app/views/manifestations/_manifestation.html.erb +59 -38
  89. data/app/views/manifestations/_pickup.html.erb +8 -0
  90. data/app/views/manifestations/_show_detail_librarian.html.erb +8 -0
  91. data/app/views/manifestations/_show_detail_user.html.erb +8 -0
  92. data/app/views/manifestations/_show_holding.html.erb +19 -0
  93. data/app/views/manifestations/_submenu_parent.html.erb +3 -0
  94. data/app/views/manifestations/index.atom.builder +3 -0
  95. data/app/views/manifestations/index.html.erb +31 -1
  96. data/app/views/manifestations/index.opds.builder +3 -0
  97. data/app/views/manifestations/show.html.erb +4 -1
  98. data/app/views/resource_export_files/index.html.erb +2 -2
  99. data/app/views/resource_export_files/show.html.erb +1 -1
  100. data/config/locales/translation_en.yml +1 -0
  101. data/config/locales/translation_ja.yml +1 -0
  102. data/db/migrate/20150117111136_add_foreign_key_to_items_referencing_manifestations.rb +5 -0
  103. data/lib/enju_biblio/biblio_helper.rb +2 -0
  104. data/lib/enju_biblio/engine.rb +0 -1
  105. data/lib/enju_biblio/version.rb +1 -1
  106. data/spec/controllers/agent_import_files_controller_spec.rb +3 -3
  107. data/spec/controllers/agent_merge_lists_controller_spec.rb +2 -2
  108. data/spec/controllers/agent_merges_controller_spec.rb +1 -1
  109. data/spec/controllers/agent_types_controller_spec.rb +8 -8
  110. data/spec/controllers/carrier_types_controller_spec.rb +8 -8
  111. data/spec/controllers/content_types_controller_spec.rb +8 -8
  112. data/spec/controllers/create_types_controller_spec.rb +6 -6
  113. data/spec/controllers/form_of_works_controller_spec.rb +6 -6
  114. data/spec/controllers/frequencies_controller_spec.rb +8 -8
  115. data/spec/controllers/identifier_types_controller_spec.rb +8 -8
  116. data/spec/controllers/licenses_controller_spec.rb +6 -6
  117. data/spec/controllers/manifestations_controller_spec.rb +22 -2
  118. data/spec/controllers/medium_of_performances_controller_spec.rb +6 -6
  119. data/spec/controllers/produce_types_controller_spec.rb +6 -6
  120. data/spec/controllers/realize_types_controller_spec.rb +6 -6
  121. data/spec/controllers/resource_export_files_controller_spec.rb +23 -23
  122. data/spec/controllers/resource_import_files_controller_spec.rb +4 -4
  123. data/spec/dummy/app/models/user.rb +0 -1
  124. data/spec/dummy/bin/bundle +3 -0
  125. data/spec/dummy/bin/rails +4 -0
  126. data/spec/dummy/bin/rake +4 -0
  127. data/spec/dummy/bin/setup +29 -0
  128. data/spec/dummy/config/application.rb +2 -2
  129. data/spec/dummy/config/boot.rb +4 -9
  130. data/spec/dummy/config/environment.rb +3 -3
  131. data/spec/dummy/db/schema.rb +118 -118
  132. data/spec/factories/manifestation.rb +8 -0
  133. data/spec/factories/series_statement.rb +5 -0
  134. data/spec/fixtures/events.yml +13 -39
  135. data/spec/fixtures/identifier_types.yml +7 -0
  136. data/spec/fixtures/identifiers.yml +7 -0
  137. data/spec/fixtures/manifestations.yml +9 -0
  138. data/spec/fixtures/use_restrictions.yml +1 -1
  139. data/spec/views/manifestations/show.html.erb_spec.rb +8 -0
  140. metadata +31 -43
  141. data/spec/dummy/db/test.sqlite3 +0 -0
  142. data/spec/dummy/script/rails +0 -6
  143. data/spec/dummy/tmp/cache/stdout +0 -25
  144. data/spec/dummy/tmp/pids/redis-test.pid +0 -1
@@ -203,7 +203,7 @@ describe ResourceImportFilesController do
203
203
  login_fixture_admin
204
204
 
205
205
  it "should update resource_import_file" do
206
- put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => { }
206
+ put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => {mode: "update"}
207
207
  expect(response).to redirect_to resource_import_file_url(assigns(:resource_import_file))
208
208
  end
209
209
  end
@@ -212,7 +212,7 @@ describe ResourceImportFilesController do
212
212
  login_fixture_librarian
213
213
 
214
214
  it "should update resource_import_file" do
215
- put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => { }
215
+ put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => {mode: "update"}
216
216
  expect(response).to redirect_to resource_import_file_url(assigns(:resource_import_file))
217
217
  end
218
218
  end
@@ -221,14 +221,14 @@ describe ResourceImportFilesController do
221
221
  login_fixture_user
222
222
 
223
223
  it "should not update resource_import_file" do
224
- put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => { }
224
+ put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => {mode: "update"}
225
225
  expect(response).to be_forbidden
226
226
  end
227
227
  end
228
228
 
229
229
  describe "When not logged in" do
230
230
  it "should not update resource_import_file" do
231
- put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => { }
231
+ put :update, :id => resource_import_files(:resource_import_file_00003).id, :resource_import_file => {mode: "update"}
232
232
  expect(response).to redirect_to new_user_session_url
233
233
  end
234
234
  end
@@ -5,7 +5,6 @@ class User < ActiveRecord::Base
5
5
  :recoverable, :rememberable, :trackable, :validatable
6
6
 
7
7
  # Setup accessible (or protected) attributes for your model
8
- attr_accessible :email, :password, :password_confirmation, :remember_me
9
8
 
10
9
  enju_leaf_user_model
11
10
  enju_circulation_user_model
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env ruby
2
+ ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
3
+ load Gem.bin_path('bundler', 'bundle')
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+ APP_PATH = File.expand_path('../../config/application', __FILE__)
3
+ require_relative '../config/boot'
4
+ require 'rails/commands'
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+ require_relative '../config/boot'
3
+ require 'rake'
4
+ Rake.application.run
@@ -0,0 +1,29 @@
1
+ #!/usr/bin/env ruby
2
+ require 'pathname'
3
+
4
+ # path to your application root.
5
+ APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
6
+
7
+ Dir.chdir APP_ROOT do
8
+ # This script is a starting point to setup your application.
9
+ # Add necessary setup steps to this file:
10
+
11
+ puts "== Installing dependencies =="
12
+ system "gem install bundler --conservative"
13
+ system "bundle check || bundle install"
14
+
15
+ # puts "\n== Copying sample files =="
16
+ # unless File.exist?("config/database.yml")
17
+ # system "cp config/database.yml.sample config/database.yml"
18
+ # end
19
+
20
+ puts "\n== Preparing database =="
21
+ system "bin/rake db:setup"
22
+
23
+ puts "\n== Removing old logs and tempfiles =="
24
+ system "rm -f log/*"
25
+ system "rm -rf tmp/cache"
26
+
27
+ puts "\n== Restarting application server =="
28
+ system "touch tmp/restart.txt"
29
+ end
@@ -2,7 +2,7 @@ require File.expand_path('../boot', __FILE__)
2
2
 
3
3
  require 'rails/all'
4
4
 
5
- Bundler.require
5
+ Bundler.require(*Rails.groups)
6
6
  require "enju_biblio"
7
7
 
8
8
  module Dummy
@@ -44,7 +44,7 @@ module Dummy
44
44
  # This will create an empty whitelist of attributes available for mass-assignment for all models
45
45
  # in your app. As such, your models will need to explicitly whitelist or blacklist accessible
46
46
  # parameters by using an attr_accessible or attr_protected declaration.
47
- config.active_record.whitelist_attributes = true
47
+ #config.active_record.whitelist_attributes = true
48
48
 
49
49
  # Enable the asset pipeline
50
50
  config.assets.enabled = true
@@ -1,10 +1,5 @@
1
- require 'rubygems'
2
- gemfile = ENV['BUNDLE_GEMFILE'] || File.expand_path('../../../../Gemfile', __FILE__)
1
+ # Set up gems listed in the Gemfile.
2
+ ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../../../Gemfile', __FILE__)
3
3
 
4
- if File.exist?(gemfile)
5
- ENV['BUNDLE_GEMFILE'] = gemfile
6
- require 'bundler'
7
- Bundler.setup
8
- end
9
-
10
- $:.unshift File.expand_path('../../../../lib', __FILE__)
4
+ require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])
5
+ $LOAD_PATH.unshift File.expand_path('../../../../lib', __FILE__)
@@ -1,5 +1,5 @@
1
- # Load the rails application
1
+ # Load the Rails application.
2
2
  require File.expand_path('../application', __FILE__)
3
3
 
4
- # Initialize the rails application
5
- Dummy::Application.initialize!
4
+ # Initialize the Rails application.
5
+ Rails.application.initialize!
@@ -11,9 +11,9 @@
11
11
  #
12
12
  # It's strongly recommended that you check this file into your version control system.
13
13
 
14
- ActiveRecord::Schema.define(version: 20141014065831) do
14
+ ActiveRecord::Schema.define(version: 20150117111136) do
15
15
 
16
- create_table "accepts", force: true do |t|
16
+ create_table "accepts", force: :cascade do |t|
17
17
  t.integer "basket_id"
18
18
  t.integer "item_id"
19
19
  t.integer "librarian_id"
@@ -24,7 +24,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
24
24
  add_index "accepts", ["basket_id"], name: "index_accepts_on_basket_id"
25
25
  add_index "accepts", ["item_id"], name: "index_accepts_on_item_id"
26
26
 
27
- create_table "agent_import_file_transitions", force: true do |t|
27
+ create_table "agent_import_file_transitions", force: :cascade do |t|
28
28
  t.string "to_state"
29
29
  t.text "metadata", default: "{}"
30
30
  t.integer "sort_key"
@@ -36,7 +36,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
36
36
  add_index "agent_import_file_transitions", ["agent_import_file_id"], name: "index_agent_import_file_transitions_on_agent_import_file_id"
37
37
  add_index "agent_import_file_transitions", ["sort_key", "agent_import_file_id"], name: "index_agent_import_file_transitions_on_sort_key_and_file_id", unique: true
38
38
 
39
- create_table "agent_import_files", force: true do |t|
39
+ create_table "agent_import_files", force: :cascade do |t|
40
40
  t.integer "parent_id"
41
41
  t.string "content_type"
42
42
  t.integer "size"
@@ -58,7 +58,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
58
58
  add_index "agent_import_files", ["parent_id"], name: "index_agent_import_files_on_parent_id"
59
59
  add_index "agent_import_files", ["user_id"], name: "index_agent_import_files_on_user_id"
60
60
 
61
- create_table "agent_import_results", force: true do |t|
61
+ create_table "agent_import_results", force: :cascade do |t|
62
62
  t.integer "agent_import_file_id"
63
63
  t.integer "agent_id"
64
64
  t.text "body"
@@ -66,13 +66,13 @@ ActiveRecord::Schema.define(version: 20141014065831) do
66
66
  t.datetime "updated_at"
67
67
  end
68
68
 
69
- create_table "agent_merge_lists", force: true do |t|
69
+ create_table "agent_merge_lists", force: :cascade do |t|
70
70
  t.string "title"
71
71
  t.datetime "created_at"
72
72
  t.datetime "updated_at"
73
73
  end
74
74
 
75
- create_table "agent_merges", force: true do |t|
75
+ create_table "agent_merges", force: :cascade do |t|
76
76
  t.integer "agent_id", null: false
77
77
  t.integer "agent_merge_list_id", null: false
78
78
  t.datetime "created_at"
@@ -82,7 +82,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
82
82
  add_index "agent_merges", ["agent_id"], name: "index_agent_merges_on_agent_id"
83
83
  add_index "agent_merges", ["agent_merge_list_id"], name: "index_agent_merges_on_agent_merge_list_id"
84
84
 
85
- create_table "agent_relationship_types", force: true do |t|
85
+ create_table "agent_relationship_types", force: :cascade do |t|
86
86
  t.string "name", null: false
87
87
  t.text "display_name"
88
88
  t.text "note"
@@ -91,7 +91,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
91
91
  t.datetime "updated_at"
92
92
  end
93
93
 
94
- create_table "agent_relationships", force: true do |t|
94
+ create_table "agent_relationships", force: :cascade do |t|
95
95
  t.integer "parent_id"
96
96
  t.integer "child_id"
97
97
  t.integer "agent_relationship_type_id"
@@ -103,7 +103,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
103
103
  add_index "agent_relationships", ["child_id"], name: "index_agent_relationships_on_child_id"
104
104
  add_index "agent_relationships", ["parent_id"], name: "index_agent_relationships_on_parent_id"
105
105
 
106
- create_table "agent_types", force: true do |t|
106
+ create_table "agent_types", force: :cascade do |t|
107
107
  t.string "name", null: false
108
108
  t.text "display_name"
109
109
  t.text "note"
@@ -112,7 +112,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
112
112
  t.datetime "updated_at"
113
113
  end
114
114
 
115
- create_table "agents", force: true do |t|
115
+ create_table "agents", force: :cascade do |t|
116
116
  t.string "last_name"
117
117
  t.string "middle_name"
118
118
  t.string "first_name"
@@ -166,7 +166,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
166
166
  add_index "agents", ["language_id"], name: "index_agents_on_language_id"
167
167
  add_index "agents", ["required_role_id"], name: "index_agents_on_required_role_id"
168
168
 
169
- create_table "baskets", force: true do |t|
169
+ create_table "baskets", force: :cascade do |t|
170
170
  t.integer "user_id"
171
171
  t.text "note"
172
172
  t.integer "lock_version", default: 0, null: false
@@ -176,7 +176,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
176
176
 
177
177
  add_index "baskets", ["user_id"], name: "index_baskets_on_user_id"
178
178
 
179
- create_table "bookmark_stat_has_manifestations", force: true do |t|
179
+ create_table "bookmark_stat_has_manifestations", force: :cascade do |t|
180
180
  t.integer "bookmark_stat_id", null: false
181
181
  t.integer "manifestation_id", null: false
182
182
  t.integer "bookmarks_count"
@@ -187,7 +187,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
187
187
  add_index "bookmark_stat_has_manifestations", ["bookmark_stat_id"], name: "index_bookmark_stat_has_manifestations_on_bookmark_stat_id"
188
188
  add_index "bookmark_stat_has_manifestations", ["manifestation_id"], name: "index_bookmark_stat_has_manifestations_on_manifestation_id"
189
189
 
190
- create_table "bookmark_stat_transitions", force: true do |t|
190
+ create_table "bookmark_stat_transitions", force: :cascade do |t|
191
191
  t.string "to_state"
192
192
  t.text "metadata", default: "{}"
193
193
  t.integer "sort_key"
@@ -199,7 +199,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
199
199
  add_index "bookmark_stat_transitions", ["bookmark_stat_id"], name: "index_bookmark_stat_transitions_on_bookmark_stat_id"
200
200
  add_index "bookmark_stat_transitions", ["sort_key", "bookmark_stat_id"], name: "index_bookmark_stat_transitions_on_sort_key_and_stat_id", unique: true
201
201
 
202
- create_table "bookmark_stats", force: true do |t|
202
+ create_table "bookmark_stats", force: :cascade do |t|
203
203
  t.datetime "start_date"
204
204
  t.datetime "end_date"
205
205
  t.datetime "started_at"
@@ -209,7 +209,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
209
209
  t.datetime "updated_at"
210
210
  end
211
211
 
212
- create_table "bookmarks", force: true do |t|
212
+ create_table "bookmarks", force: :cascade do |t|
213
213
  t.integer "user_id", null: false
214
214
  t.integer "manifestation_id"
215
215
  t.text "title"
@@ -224,7 +224,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
224
224
  add_index "bookmarks", ["url"], name: "index_bookmarks_on_url"
225
225
  add_index "bookmarks", ["user_id"], name: "index_bookmarks_on_user_id"
226
226
 
227
- create_table "bookstores", force: true do |t|
227
+ create_table "bookstores", force: :cascade do |t|
228
228
  t.text "name", null: false
229
229
  t.string "zip_code"
230
230
  t.text "address"
@@ -238,7 +238,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
238
238
  t.datetime "updated_at"
239
239
  end
240
240
 
241
- create_table "budget_types", force: true do |t|
241
+ create_table "budget_types", force: :cascade do |t|
242
242
  t.string "name"
243
243
  t.text "display_name"
244
244
  t.text "note"
@@ -247,7 +247,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
247
247
  t.datetime "updated_at"
248
248
  end
249
249
 
250
- create_table "carrier_type_has_checkout_types", force: true do |t|
250
+ create_table "carrier_type_has_checkout_types", force: :cascade do |t|
251
251
  t.integer "carrier_type_id", null: false
252
252
  t.integer "checkout_type_id", null: false
253
253
  t.text "note"
@@ -259,7 +259,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
259
259
  add_index "carrier_type_has_checkout_types", ["carrier_type_id"], name: "index_carrier_type_has_checkout_types_on_m_form_id"
260
260
  add_index "carrier_type_has_checkout_types", ["checkout_type_id"], name: "index_carrier_type_has_checkout_types_on_checkout_type_id"
261
261
 
262
- create_table "carrier_types", force: true do |t|
262
+ create_table "carrier_types", force: :cascade do |t|
263
263
  t.string "name", null: false
264
264
  t.text "display_name"
265
265
  t.text "note"
@@ -268,7 +268,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
268
268
  t.datetime "updated_at"
269
269
  end
270
270
 
271
- create_table "checked_items", force: true do |t|
271
+ create_table "checked_items", force: :cascade do |t|
272
272
  t.integer "item_id", null: false
273
273
  t.integer "basket_id", null: false
274
274
  t.datetime "due_date", null: false
@@ -280,7 +280,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
280
280
  add_index "checked_items", ["basket_id"], name: "index_checked_items_on_basket_id"
281
281
  add_index "checked_items", ["item_id"], name: "index_checked_items_on_item_id"
282
282
 
283
- create_table "checkins", force: true do |t|
283
+ create_table "checkins", force: :cascade do |t|
284
284
  t.integer "item_id", null: false
285
285
  t.integer "librarian_id"
286
286
  t.integer "basket_id"
@@ -293,7 +293,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
293
293
  add_index "checkins", ["item_id"], name: "index_checkins_on_item_id"
294
294
  add_index "checkins", ["librarian_id"], name: "index_checkins_on_librarian_id"
295
295
 
296
- create_table "checkout_stat_has_manifestations", force: true do |t|
296
+ create_table "checkout_stat_has_manifestations", force: :cascade do |t|
297
297
  t.integer "manifestation_checkout_stat_id", null: false
298
298
  t.integer "manifestation_id", null: false
299
299
  t.integer "checkouts_count"
@@ -304,7 +304,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
304
304
  add_index "checkout_stat_has_manifestations", ["manifestation_checkout_stat_id"], name: "index_checkout_stat_has_manifestations_on_checkout_stat_id"
305
305
  add_index "checkout_stat_has_manifestations", ["manifestation_id"], name: "index_checkout_stat_has_manifestations_on_manifestation_id"
306
306
 
307
- create_table "checkout_stat_has_users", force: true do |t|
307
+ create_table "checkout_stat_has_users", force: :cascade do |t|
308
308
  t.integer "user_checkout_stat_id", null: false
309
309
  t.integer "user_id", null: false
310
310
  t.integer "checkouts_count", default: 0, null: false
@@ -315,7 +315,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
315
315
  add_index "checkout_stat_has_users", ["user_checkout_stat_id"], name: "index_checkout_stat_has_users_on_user_checkout_stat_id"
316
316
  add_index "checkout_stat_has_users", ["user_id"], name: "index_checkout_stat_has_users_on_user_id"
317
317
 
318
- create_table "checkout_types", force: true do |t|
318
+ create_table "checkout_types", force: :cascade do |t|
319
319
  t.string "name", null: false
320
320
  t.text "display_name"
321
321
  t.text "note"
@@ -326,7 +326,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
326
326
 
327
327
  add_index "checkout_types", ["name"], name: "index_checkout_types_on_name"
328
328
 
329
- create_table "checkouts", force: true do |t|
329
+ create_table "checkouts", force: :cascade do |t|
330
330
  t.integer "user_id"
331
331
  t.integer "item_id", null: false
332
332
  t.integer "checkin_id"
@@ -348,7 +348,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
348
348
  add_index "checkouts", ["shelf_id"], name: "index_checkouts_on_shelf_id"
349
349
  add_index "checkouts", ["user_id"], name: "index_checkouts_on_user_id"
350
350
 
351
- create_table "circulation_statuses", force: true do |t|
351
+ create_table "circulation_statuses", force: :cascade do |t|
352
352
  t.string "name", null: false
353
353
  t.text "display_name"
354
354
  t.text "note"
@@ -357,7 +357,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
357
357
  t.datetime "updated_at"
358
358
  end
359
359
 
360
- create_table "classification_types", force: true do |t|
360
+ create_table "classification_types", force: :cascade do |t|
361
361
  t.string "name", null: false
362
362
  t.text "display_name"
363
363
  t.text "note"
@@ -366,7 +366,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
366
366
  t.datetime "updated_at"
367
367
  end
368
368
 
369
- create_table "classifications", force: true do |t|
369
+ create_table "classifications", force: :cascade do |t|
370
370
  t.integer "parent_id"
371
371
  t.string "category", null: false
372
372
  t.text "note"
@@ -383,7 +383,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
383
383
  add_index "classifications", ["manifestation_id"], name: "index_classifications_on_manifestation_id"
384
384
  add_index "classifications", ["parent_id"], name: "index_classifications_on_parent_id"
385
385
 
386
- create_table "colors", force: true do |t|
386
+ create_table "colors", force: :cascade do |t|
387
387
  t.integer "library_group_id"
388
388
  t.string "property"
389
389
  t.string "code"
@@ -394,7 +394,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
394
394
 
395
395
  add_index "colors", ["library_group_id"], name: "index_colors_on_library_group_id"
396
396
 
397
- create_table "content_types", force: true do |t|
397
+ create_table "content_types", force: :cascade do |t|
398
398
  t.string "name", null: false
399
399
  t.text "display_name"
400
400
  t.text "note"
@@ -403,7 +403,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
403
403
  t.datetime "updated_at"
404
404
  end
405
405
 
406
- create_table "countries", force: true do |t|
406
+ create_table "countries", force: :cascade do |t|
407
407
  t.string "name", null: false
408
408
  t.text "display_name"
409
409
  t.string "alpha_2"
@@ -418,7 +418,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
418
418
  add_index "countries", ["name"], name: "index_countries_on_name"
419
419
  add_index "countries", ["numeric_3"], name: "index_countries_on_numeric_3"
420
420
 
421
- create_table "create_types", force: true do |t|
421
+ create_table "create_types", force: :cascade do |t|
422
422
  t.string "name"
423
423
  t.text "display_name"
424
424
  t.text "note"
@@ -427,7 +427,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
427
427
  t.datetime "updated_at"
428
428
  end
429
429
 
430
- create_table "creates", force: true do |t|
430
+ create_table "creates", force: :cascade do |t|
431
431
  t.integer "agent_id", null: false
432
432
  t.integer "work_id", null: false
433
433
  t.integer "position"
@@ -439,7 +439,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
439
439
  add_index "creates", ["agent_id"], name: "index_creates_on_agent_id"
440
440
  add_index "creates", ["work_id"], name: "index_creates_on_work_id"
441
441
 
442
- create_table "donates", force: true do |t|
442
+ create_table "donates", force: :cascade do |t|
443
443
  t.integer "agent_id", null: false
444
444
  t.integer "item_id", null: false
445
445
  t.datetime "created_at"
@@ -449,7 +449,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
449
449
  add_index "donates", ["agent_id"], name: "index_donates_on_agent_id"
450
450
  add_index "donates", ["item_id"], name: "index_donates_on_item_id"
451
451
 
452
- create_table "event_categories", force: true do |t|
452
+ create_table "event_categories", force: :cascade do |t|
453
453
  t.string "name", null: false
454
454
  t.text "display_name"
455
455
  t.text "note"
@@ -458,7 +458,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
458
458
  t.datetime "updated_at"
459
459
  end
460
460
 
461
- create_table "event_export_file_transitions", force: true do |t|
461
+ create_table "event_export_file_transitions", force: :cascade do |t|
462
462
  t.string "to_state"
463
463
  t.text "metadata", default: "{}"
464
464
  t.integer "sort_key"
@@ -470,7 +470,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
470
470
  add_index "event_export_file_transitions", ["event_export_file_id"], name: "index_event_export_file_transitions_on_file_id"
471
471
  add_index "event_export_file_transitions", ["sort_key", "event_export_file_id"], name: "index_event_export_file_transitions_on_sort_key_and_file_id", unique: true
472
472
 
473
- create_table "event_export_files", force: true do |t|
473
+ create_table "event_export_files", force: :cascade do |t|
474
474
  t.integer "user_id"
475
475
  t.string "event_export_file_name"
476
476
  t.string "event_export_content_type"
@@ -481,7 +481,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
481
481
  t.datetime "updated_at"
482
482
  end
483
483
 
484
- create_table "event_import_file_transitions", force: true do |t|
484
+ create_table "event_import_file_transitions", force: :cascade do |t|
485
485
  t.string "to_state"
486
486
  t.text "metadata", default: "{}"
487
487
  t.integer "sort_key"
@@ -493,7 +493,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
493
493
  add_index "event_import_file_transitions", ["event_import_file_id"], name: "index_event_import_file_transitions_on_event_import_file_id"
494
494
  add_index "event_import_file_transitions", ["sort_key", "event_import_file_id"], name: "index_event_import_file_transitions_on_sort_key_and_file_id", unique: true
495
495
 
496
- create_table "event_import_files", force: true do |t|
496
+ create_table "event_import_files", force: :cascade do |t|
497
497
  t.integer "parent_id"
498
498
  t.string "content_type"
499
499
  t.integer "size"
@@ -517,7 +517,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
517
517
  add_index "event_import_files", ["parent_id"], name: "index_event_import_files_on_parent_id"
518
518
  add_index "event_import_files", ["user_id"], name: "index_event_import_files_on_user_id"
519
519
 
520
- create_table "event_import_results", force: true do |t|
520
+ create_table "event_import_results", force: :cascade do |t|
521
521
  t.integer "event_import_file_id"
522
522
  t.integer "event_id"
523
523
  t.text "body"
@@ -525,7 +525,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
525
525
  t.datetime "updated_at"
526
526
  end
527
527
 
528
- create_table "events", force: true do |t|
528
+ create_table "events", force: :cascade do |t|
529
529
  t.integer "library_id", null: false
530
530
  t.integer "event_category_id", null: false
531
531
  t.string "name"
@@ -542,7 +542,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
542
542
  add_index "events", ["event_category_id"], name: "index_events_on_event_category_id"
543
543
  add_index "events", ["library_id"], name: "index_events_on_library_id"
544
544
 
545
- create_table "exemplifies", force: true do |t|
545
+ create_table "exemplifies", force: :cascade do |t|
546
546
  t.integer "manifestation_id", null: false
547
547
  t.integer "item_id", null: false
548
548
  t.integer "position"
@@ -553,7 +553,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
553
553
  add_index "exemplifies", ["item_id"], name: "index_exemplifies_on_item_id", unique: true
554
554
  add_index "exemplifies", ["manifestation_id"], name: "index_exemplifies_on_manifestation_id"
555
555
 
556
- create_table "form_of_works", force: true do |t|
556
+ create_table "form_of_works", force: :cascade do |t|
557
557
  t.string "name", null: false
558
558
  t.text "display_name"
559
559
  t.text "note"
@@ -562,7 +562,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
562
562
  t.datetime "updated_at"
563
563
  end
564
564
 
565
- create_table "frequencies", force: true do |t|
565
+ create_table "frequencies", force: :cascade do |t|
566
566
  t.string "name", null: false
567
567
  t.text "display_name"
568
568
  t.text "note"
@@ -571,7 +571,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
571
571
  t.datetime "updated_at"
572
572
  end
573
573
 
574
- create_table "identifier_types", force: true do |t|
574
+ create_table "identifier_types", force: :cascade do |t|
575
575
  t.string "name"
576
576
  t.text "display_name"
577
577
  t.text "note"
@@ -580,7 +580,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
580
580
  t.datetime "updated_at"
581
581
  end
582
582
 
583
- create_table "identifiers", force: true do |t|
583
+ create_table "identifiers", force: :cascade do |t|
584
584
  t.string "body", null: false
585
585
  t.integer "identifier_type_id", null: false
586
586
  t.integer "manifestation_id"
@@ -593,7 +593,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
593
593
  add_index "identifiers", ["body", "identifier_type_id"], name: "index_identifiers_on_body_and_identifier_type_id"
594
594
  add_index "identifiers", ["manifestation_id"], name: "index_identifiers_on_manifestation_id"
595
595
 
596
- create_table "import_request_transitions", force: true do |t|
596
+ create_table "import_request_transitions", force: :cascade do |t|
597
597
  t.string "to_state"
598
598
  t.text "metadata", default: "{}"
599
599
  t.integer "sort_key"
@@ -605,7 +605,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
605
605
  add_index "import_request_transitions", ["import_request_id"], name: "index_import_request_transitions_on_import_request_id"
606
606
  add_index "import_request_transitions", ["sort_key", "import_request_id"], name: "index_import_request_transitions_on_sort_key_and_request_id", unique: true
607
607
 
608
- create_table "import_requests", force: true do |t|
608
+ create_table "import_requests", force: :cascade do |t|
609
609
  t.string "isbn"
610
610
  t.integer "manifestation_id"
611
611
  t.integer "user_id"
@@ -617,7 +617,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
617
617
  add_index "import_requests", ["manifestation_id"], name: "index_import_requests_on_manifestation_id"
618
618
  add_index "import_requests", ["user_id"], name: "index_import_requests_on_user_id"
619
619
 
620
- create_table "inventories", force: true do |t|
620
+ create_table "inventories", force: :cascade do |t|
621
621
  t.integer "item_id"
622
622
  t.integer "inventory_file_id"
623
623
  t.text "note"
@@ -628,7 +628,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
628
628
  add_index "inventories", ["inventory_file_id"], name: "index_inventories_on_inventory_file_id"
629
629
  add_index "inventories", ["item_id"], name: "index_inventories_on_item_id"
630
630
 
631
- create_table "inventory_files", force: true do |t|
631
+ create_table "inventory_files", force: :cascade do |t|
632
632
  t.string "filename"
633
633
  t.string "content_type"
634
634
  t.integer "size"
@@ -645,7 +645,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
645
645
 
646
646
  add_index "inventory_files", ["user_id"], name: "index_inventory_files_on_user_id"
647
647
 
648
- create_table "item_has_use_restrictions", force: true do |t|
648
+ create_table "item_has_use_restrictions", force: :cascade do |t|
649
649
  t.integer "item_id", null: false
650
650
  t.integer "use_restriction_id", null: false
651
651
  t.datetime "created_at"
@@ -655,7 +655,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
655
655
  add_index "item_has_use_restrictions", ["item_id"], name: "index_item_has_use_restrictions_on_item_id"
656
656
  add_index "item_has_use_restrictions", ["use_restriction_id"], name: "index_item_has_use_restrictions_on_use_restriction_id"
657
657
 
658
- create_table "items", force: true do |t|
658
+ create_table "items", force: :cascade do |t|
659
659
  t.string "call_number"
660
660
  t.string "item_identifier"
661
661
  t.datetime "created_at"
@@ -689,7 +689,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
689
689
  add_index "items", ["required_role_id"], name: "index_items_on_required_role_id"
690
690
  add_index "items", ["shelf_id"], name: "index_items_on_shelf_id"
691
691
 
692
- create_table "languages", force: true do |t|
692
+ create_table "languages", force: :cascade do |t|
693
693
  t.string "name", null: false
694
694
  t.string "native_name"
695
695
  t.text "display_name"
@@ -705,7 +705,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
705
705
  add_index "languages", ["iso_639_3"], name: "index_languages_on_iso_639_3"
706
706
  add_index "languages", ["name"], name: "index_languages_on_name", unique: true
707
707
 
708
- create_table "lending_policies", force: true do |t|
708
+ create_table "lending_policies", force: :cascade do |t|
709
709
  t.integer "item_id", null: false
710
710
  t.integer "user_group_id", null: false
711
711
  t.integer "loan_period", default: 0, null: false
@@ -720,7 +720,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
720
720
 
721
721
  add_index "lending_policies", ["item_id", "user_group_id"], name: "index_lending_policies_on_item_id_and_user_group_id", unique: true
722
722
 
723
- create_table "libraries", force: true do |t|
723
+ create_table "libraries", force: :cascade do |t|
724
724
  t.string "name", null: false
725
725
  t.text "display_name"
726
726
  t.string "short_display_name", null: false
@@ -750,7 +750,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
750
750
  add_index "libraries", ["library_group_id"], name: "index_libraries_on_library_group_id"
751
751
  add_index "libraries", ["name"], name: "index_libraries_on_name", unique: true
752
752
 
753
- create_table "library_groups", force: true do |t|
753
+ create_table "library_groups", force: :cascade do |t|
754
754
  t.string "name", null: false
755
755
  t.text "display_name"
756
756
  t.string "short_name", null: false
@@ -768,7 +768,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
768
768
 
769
769
  add_index "library_groups", ["short_name"], name: "index_library_groups_on_short_name"
770
770
 
771
- create_table "licenses", force: true do |t|
771
+ create_table "licenses", force: :cascade do |t|
772
772
  t.string "name", null: false
773
773
  t.string "display_name"
774
774
  t.text "note"
@@ -777,7 +777,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
777
777
  t.datetime "updated_at"
778
778
  end
779
779
 
780
- create_table "manifestation_checkout_stat_transitions", force: true do |t|
780
+ create_table "manifestation_checkout_stat_transitions", force: :cascade do |t|
781
781
  t.string "to_state"
782
782
  t.text "metadata", default: "{}"
783
783
  t.integer "sort_key"
@@ -789,7 +789,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
789
789
  add_index "manifestation_checkout_stat_transitions", ["manifestation_checkout_stat_id"], name: "index_manifestation_checkout_stat_transitions_on_stat_id"
790
790
  add_index "manifestation_checkout_stat_transitions", ["sort_key", "manifestation_checkout_stat_id"], name: "index_manifestation_checkout_stat_transitions_on_transition", unique: true
791
791
 
792
- create_table "manifestation_checkout_stats", force: true do |t|
792
+ create_table "manifestation_checkout_stats", force: :cascade do |t|
793
793
  t.datetime "start_date"
794
794
  t.datetime "end_date"
795
795
  t.text "note"
@@ -802,7 +802,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
802
802
 
803
803
  add_index "manifestation_checkout_stats", ["user_id"], name: "index_manifestation_checkout_stats_on_user_id"
804
804
 
805
- create_table "manifestation_relationship_types", force: true do |t|
805
+ create_table "manifestation_relationship_types", force: :cascade do |t|
806
806
  t.string "name", null: false
807
807
  t.text "display_name"
808
808
  t.text "note"
@@ -811,7 +811,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
811
811
  t.datetime "updated_at"
812
812
  end
813
813
 
814
- create_table "manifestation_relationships", force: true do |t|
814
+ create_table "manifestation_relationships", force: :cascade do |t|
815
815
  t.integer "parent_id"
816
816
  t.integer "child_id"
817
817
  t.integer "manifestation_relationship_type_id"
@@ -823,7 +823,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
823
823
  add_index "manifestation_relationships", ["child_id"], name: "index_manifestation_relationships_on_child_id"
824
824
  add_index "manifestation_relationships", ["parent_id"], name: "index_manifestation_relationships_on_parent_id"
825
825
 
826
- create_table "manifestation_reserve_stat_transitions", force: true do |t|
826
+ create_table "manifestation_reserve_stat_transitions", force: :cascade do |t|
827
827
  t.string "to_state"
828
828
  t.text "metadata", default: "{}"
829
829
  t.integer "sort_key"
@@ -835,7 +835,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
835
835
  add_index "manifestation_reserve_stat_transitions", ["manifestation_reserve_stat_id"], name: "index_manifestation_reserve_stat_transitions_on_stat_id"
836
836
  add_index "manifestation_reserve_stat_transitions", ["sort_key", "manifestation_reserve_stat_id"], name: "index_manifestation_reserve_stat_transitions_on_transition", unique: true
837
837
 
838
- create_table "manifestation_reserve_stats", force: true do |t|
838
+ create_table "manifestation_reserve_stats", force: :cascade do |t|
839
839
  t.datetime "start_date"
840
840
  t.datetime "end_date"
841
841
  t.text "note"
@@ -848,7 +848,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
848
848
 
849
849
  add_index "manifestation_reserve_stats", ["user_id"], name: "index_manifestation_reserve_stats_on_user_id"
850
850
 
851
- create_table "manifestations", force: true do |t|
851
+ create_table "manifestations", force: :cascade do |t|
852
852
  t.text "original_title", null: false
853
853
  t.text "title_alternative"
854
854
  t.text "title_transcription"
@@ -914,7 +914,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
914
914
  add_index "manifestations", ["manifestation_identifier"], name: "index_manifestations_on_manifestation_identifier"
915
915
  add_index "manifestations", ["updated_at"], name: "index_manifestations_on_updated_at"
916
916
 
917
- create_table "medium_of_performances", force: true do |t|
917
+ create_table "medium_of_performances", force: :cascade do |t|
918
918
  t.string "name", null: false
919
919
  t.text "display_name"
920
920
  t.text "note"
@@ -923,7 +923,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
923
923
  t.datetime "updated_at"
924
924
  end
925
925
 
926
- create_table "message_request_transitions", force: true do |t|
926
+ create_table "message_request_transitions", force: :cascade do |t|
927
927
  t.string "to_state"
928
928
  t.text "metadata", default: "{}"
929
929
  t.integer "sort_key"
@@ -935,7 +935,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
935
935
  add_index "message_request_transitions", ["message_request_id"], name: "index_message_request_transitions_on_message_request_id"
936
936
  add_index "message_request_transitions", ["sort_key", "message_request_id"], name: "index_message_request_transitions_on_sort_key_and_request_id", unique: true
937
937
 
938
- create_table "message_requests", force: true do |t|
938
+ create_table "message_requests", force: :cascade do |t|
939
939
  t.integer "sender_id"
940
940
  t.integer "receiver_id"
941
941
  t.integer "message_template_id"
@@ -946,7 +946,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
946
946
  t.datetime "updated_at"
947
947
  end
948
948
 
949
- create_table "message_templates", force: true do |t|
949
+ create_table "message_templates", force: :cascade do |t|
950
950
  t.string "status", null: false
951
951
  t.text "title", null: false
952
952
  t.text "body", null: false
@@ -958,7 +958,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
958
958
 
959
959
  add_index "message_templates", ["status"], name: "index_message_templates_on_status", unique: true
960
960
 
961
- create_table "message_transitions", force: true do |t|
961
+ create_table "message_transitions", force: :cascade do |t|
962
962
  t.string "to_state"
963
963
  t.text "metadata", default: "{}"
964
964
  t.integer "sort_key"
@@ -970,7 +970,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
970
970
  add_index "message_transitions", ["message_id"], name: "index_message_transitions_on_message_id"
971
971
  add_index "message_transitions", ["sort_key", "message_id"], name: "index_message_transitions_on_sort_key_and_message_id", unique: true
972
972
 
973
- create_table "messages", force: true do |t|
973
+ create_table "messages", force: :cascade do |t|
974
974
  t.datetime "read_at"
975
975
  t.integer "receiver_id"
976
976
  t.integer "sender_id"
@@ -990,7 +990,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
990
990
  add_index "messages", ["receiver_id"], name: "index_messages_on_receiver_id"
991
991
  add_index "messages", ["sender_id"], name: "index_messages_on_sender_id"
992
992
 
993
- create_table "owns", force: true do |t|
993
+ create_table "owns", force: :cascade do |t|
994
994
  t.integer "agent_id", null: false
995
995
  t.integer "item_id", null: false
996
996
  t.integer "position"
@@ -1001,7 +1001,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1001
1001
  add_index "owns", ["agent_id"], name: "index_owns_on_agent_id"
1002
1002
  add_index "owns", ["item_id"], name: "index_owns_on_item_id"
1003
1003
 
1004
- create_table "participates", force: true do |t|
1004
+ create_table "participates", force: :cascade do |t|
1005
1005
  t.integer "agent_id", null: false
1006
1006
  t.integer "event_id", null: false
1007
1007
  t.integer "position"
@@ -1012,7 +1012,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1012
1012
  add_index "participates", ["agent_id"], name: "index_participates_on_agent_id"
1013
1013
  add_index "participates", ["event_id"], name: "index_participates_on_event_id"
1014
1014
 
1015
- create_table "picture_files", force: true do |t|
1015
+ create_table "picture_files", force: :cascade do |t|
1016
1016
  t.integer "picture_attachable_id"
1017
1017
  t.string "picture_attachable_type"
1018
1018
  t.string "content_type"
@@ -1031,7 +1031,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1031
1031
 
1032
1032
  add_index "picture_files", ["picture_attachable_id", "picture_attachable_type"], name: "index_picture_files_on_picture_attachable_id_and_type"
1033
1033
 
1034
- create_table "produce_types", force: true do |t|
1034
+ create_table "produce_types", force: :cascade do |t|
1035
1035
  t.string "name"
1036
1036
  t.text "display_name"
1037
1037
  t.text "note"
@@ -1040,7 +1040,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1040
1040
  t.datetime "updated_at"
1041
1041
  end
1042
1042
 
1043
- create_table "produces", force: true do |t|
1043
+ create_table "produces", force: :cascade do |t|
1044
1044
  t.integer "agent_id", null: false
1045
1045
  t.integer "manifestation_id", null: false
1046
1046
  t.integer "position"
@@ -1052,7 +1052,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1052
1052
  add_index "produces", ["agent_id"], name: "index_produces_on_agent_id"
1053
1053
  add_index "produces", ["manifestation_id"], name: "index_produces_on_manifestation_id"
1054
1054
 
1055
- create_table "profiles", force: true do |t|
1055
+ create_table "profiles", force: :cascade do |t|
1056
1056
  t.integer "user_id"
1057
1057
  t.integer "user_group_id"
1058
1058
  t.integer "library_id"
@@ -1076,7 +1076,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1076
1076
  add_index "profiles", ["user_id"], name: "index_profiles_on_user_id"
1077
1077
  add_index "profiles", ["user_number"], name: "index_profiles_on_user_number", unique: true
1078
1078
 
1079
- create_table "realize_types", force: true do |t|
1079
+ create_table "realize_types", force: :cascade do |t|
1080
1080
  t.string "name"
1081
1081
  t.text "display_name"
1082
1082
  t.text "note"
@@ -1085,7 +1085,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1085
1085
  t.datetime "updated_at"
1086
1086
  end
1087
1087
 
1088
- create_table "realizes", force: true do |t|
1088
+ create_table "realizes", force: :cascade do |t|
1089
1089
  t.integer "agent_id", null: false
1090
1090
  t.integer "expression_id", null: false
1091
1091
  t.integer "position"
@@ -1097,7 +1097,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1097
1097
  add_index "realizes", ["agent_id"], name: "index_realizes_on_agent_id"
1098
1098
  add_index "realizes", ["expression_id"], name: "index_realizes_on_expression_id"
1099
1099
 
1100
- create_table "request_status_types", force: true do |t|
1100
+ create_table "request_status_types", force: :cascade do |t|
1101
1101
  t.string "name", null: false
1102
1102
  t.text "display_name"
1103
1103
  t.text "note"
@@ -1106,7 +1106,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1106
1106
  t.datetime "updated_at"
1107
1107
  end
1108
1108
 
1109
- create_table "request_types", force: true do |t|
1109
+ create_table "request_types", force: :cascade do |t|
1110
1110
  t.string "name", null: false
1111
1111
  t.text "display_name"
1112
1112
  t.text "note"
@@ -1115,7 +1115,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1115
1115
  t.datetime "updated_at"
1116
1116
  end
1117
1117
 
1118
- create_table "reserve_stat_has_manifestations", force: true do |t|
1118
+ create_table "reserve_stat_has_manifestations", force: :cascade do |t|
1119
1119
  t.integer "manifestation_reserve_stat_id", null: false
1120
1120
  t.integer "manifestation_id", null: false
1121
1121
  t.integer "reserves_count"
@@ -1126,7 +1126,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1126
1126
  add_index "reserve_stat_has_manifestations", ["manifestation_id"], name: "index_reserve_stat_has_manifestations_on_manifestation_id"
1127
1127
  add_index "reserve_stat_has_manifestations", ["manifestation_reserve_stat_id"], name: "index_reserve_stat_has_manifestations_on_m_reserve_stat_id"
1128
1128
 
1129
- create_table "reserve_stat_has_users", force: true do |t|
1129
+ create_table "reserve_stat_has_users", force: :cascade do |t|
1130
1130
  t.integer "user_reserve_stat_id", null: false
1131
1131
  t.integer "user_id", null: false
1132
1132
  t.integer "reserves_count"
@@ -1137,7 +1137,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1137
1137
  add_index "reserve_stat_has_users", ["user_id"], name: "index_reserve_stat_has_users_on_user_id"
1138
1138
  add_index "reserve_stat_has_users", ["user_reserve_stat_id"], name: "index_reserve_stat_has_users_on_user_reserve_stat_id"
1139
1139
 
1140
- create_table "reserve_transitions", force: true do |t|
1140
+ create_table "reserve_transitions", force: :cascade do |t|
1141
1141
  t.string "to_state"
1142
1142
  t.text "metadata", default: "{}"
1143
1143
  t.integer "sort_key"
@@ -1149,7 +1149,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1149
1149
  add_index "reserve_transitions", ["reserve_id"], name: "index_reserve_transitions_on_reserve_id"
1150
1150
  add_index "reserve_transitions", ["sort_key", "reserve_id"], name: "index_reserve_transitions_on_sort_key_and_reserve_id", unique: true
1151
1151
 
1152
- create_table "reserves", force: true do |t|
1152
+ create_table "reserves", force: :cascade do |t|
1153
1153
  t.integer "user_id", null: false
1154
1154
  t.integer "manifestation_id", null: false
1155
1155
  t.integer "item_id"
@@ -1172,7 +1172,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1172
1172
  add_index "reserves", ["request_status_type_id"], name: "index_reserves_on_request_status_type_id"
1173
1173
  add_index "reserves", ["user_id"], name: "index_reserves_on_user_id"
1174
1174
 
1175
- create_table "resource_export_file_transitions", force: true do |t|
1175
+ create_table "resource_export_file_transitions", force: :cascade do |t|
1176
1176
  t.string "to_state"
1177
1177
  t.text "metadata", default: "{}"
1178
1178
  t.integer "sort_key"
@@ -1184,7 +1184,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1184
1184
  add_index "resource_export_file_transitions", ["resource_export_file_id"], name: "index_resource_export_file_transitions_on_file_id"
1185
1185
  add_index "resource_export_file_transitions", ["sort_key", "resource_export_file_id"], name: "index_resource_export_file_transitions_on_sort_key_and_file_id", unique: true
1186
1186
 
1187
- create_table "resource_export_files", force: true do |t|
1187
+ create_table "resource_export_files", force: :cascade do |t|
1188
1188
  t.integer "user_id"
1189
1189
  t.string "resource_export_file_name"
1190
1190
  t.string "resource_export_content_type"
@@ -1195,7 +1195,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1195
1195
  t.datetime "updated_at"
1196
1196
  end
1197
1197
 
1198
- create_table "resource_import_file_transitions", force: true do |t|
1198
+ create_table "resource_import_file_transitions", force: :cascade do |t|
1199
1199
  t.string "to_state"
1200
1200
  t.text "metadata", default: "{}"
1201
1201
  t.integer "sort_key"
@@ -1207,7 +1207,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1207
1207
  add_index "resource_import_file_transitions", ["resource_import_file_id"], name: "index_resource_import_file_transitions_on_file_id"
1208
1208
  add_index "resource_import_file_transitions", ["sort_key", "resource_import_file_id"], name: "index_resource_import_file_transitions_on_sort_key_and_file_id", unique: true
1209
1209
 
1210
- create_table "resource_import_files", force: true do |t|
1210
+ create_table "resource_import_files", force: :cascade do |t|
1211
1211
  t.integer "parent_id"
1212
1212
  t.string "content_type"
1213
1213
  t.integer "size"
@@ -1230,7 +1230,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1230
1230
  add_index "resource_import_files", ["parent_id"], name: "index_resource_import_files_on_parent_id"
1231
1231
  add_index "resource_import_files", ["user_id"], name: "index_resource_import_files_on_user_id"
1232
1232
 
1233
- create_table "resource_import_results", force: true do |t|
1233
+ create_table "resource_import_results", force: :cascade do |t|
1234
1234
  t.integer "resource_import_file_id"
1235
1235
  t.integer "manifestation_id"
1236
1236
  t.integer "item_id"
@@ -1244,7 +1244,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1244
1244
  add_index "resource_import_results", ["manifestation_id"], name: "index_resource_import_results_on_manifestation_id"
1245
1245
  add_index "resource_import_results", ["resource_import_file_id"], name: "index_resource_import_results_on_resource_import_file_id"
1246
1246
 
1247
- create_table "roles", force: true do |t|
1247
+ create_table "roles", force: :cascade do |t|
1248
1248
  t.string "name", null: false
1249
1249
  t.string "display_name"
1250
1250
  t.text "note"
@@ -1254,7 +1254,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1254
1254
  t.integer "position"
1255
1255
  end
1256
1256
 
1257
- create_table "search_engines", force: true do |t|
1257
+ create_table "search_engines", force: :cascade do |t|
1258
1258
  t.string "name", null: false
1259
1259
  t.text "display_name"
1260
1260
  t.string "url", null: false
@@ -1268,13 +1268,13 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1268
1268
  t.datetime "updated_at"
1269
1269
  end
1270
1270
 
1271
- create_table "series_statement_merge_lists", force: true do |t|
1271
+ create_table "series_statement_merge_lists", force: :cascade do |t|
1272
1272
  t.string "title"
1273
1273
  t.datetime "created_at"
1274
1274
  t.datetime "updated_at"
1275
1275
  end
1276
1276
 
1277
- create_table "series_statement_merges", force: true do |t|
1277
+ create_table "series_statement_merges", force: :cascade do |t|
1278
1278
  t.integer "series_statement_id", null: false
1279
1279
  t.integer "series_statement_merge_list_id", null: false
1280
1280
  t.datetime "created_at"
@@ -1284,7 +1284,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1284
1284
  add_index "series_statement_merges", ["series_statement_id"], name: "index_series_statement_merges_on_series_statement_id"
1285
1285
  add_index "series_statement_merges", ["series_statement_merge_list_id"], name: "index_series_statement_merges_on_list_id"
1286
1286
 
1287
- create_table "series_statements", force: true do |t|
1287
+ create_table "series_statements", force: :cascade do |t|
1288
1288
  t.text "original_title"
1289
1289
  t.text "numbering"
1290
1290
  t.text "title_subseries"
@@ -1309,7 +1309,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1309
1309
  add_index "series_statements", ["root_manifestation_id"], name: "index_series_statements_on_root_manifestation_id"
1310
1310
  add_index "series_statements", ["series_statement_identifier"], name: "index_series_statements_on_series_statement_identifier"
1311
1311
 
1312
- create_table "shelves", force: true do |t|
1312
+ create_table "shelves", force: :cascade do |t|
1313
1313
  t.string "name", null: false
1314
1314
  t.text "display_name"
1315
1315
  t.text "note"
@@ -1324,7 +1324,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1324
1324
 
1325
1325
  add_index "shelves", ["library_id"], name: "index_shelves_on_library_id"
1326
1326
 
1327
- create_table "subject_heading_types", force: true do |t|
1327
+ create_table "subject_heading_types", force: :cascade do |t|
1328
1328
  t.string "name", null: false
1329
1329
  t.text "display_name"
1330
1330
  t.text "note"
@@ -1333,7 +1333,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1333
1333
  t.datetime "updated_at"
1334
1334
  end
1335
1335
 
1336
- create_table "subject_types", force: true do |t|
1336
+ create_table "subject_types", force: :cascade do |t|
1337
1337
  t.string "name", null: false
1338
1338
  t.text "display_name"
1339
1339
  t.text "note"
@@ -1342,7 +1342,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1342
1342
  t.datetime "updated_at"
1343
1343
  end
1344
1344
 
1345
- create_table "subjects", force: true do |t|
1345
+ create_table "subjects", force: :cascade do |t|
1346
1346
  t.integer "parent_id"
1347
1347
  t.integer "use_term_id"
1348
1348
  t.string "term"
@@ -1367,7 +1367,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1367
1367
  add_index "subjects", ["term"], name: "index_subjects_on_term"
1368
1368
  add_index "subjects", ["use_term_id"], name: "index_subjects_on_use_term_id"
1369
1369
 
1370
- create_table "subscribes", force: true do |t|
1370
+ create_table "subscribes", force: :cascade do |t|
1371
1371
  t.integer "subscription_id", null: false
1372
1372
  t.integer "work_id", null: false
1373
1373
  t.datetime "start_at", null: false
@@ -1379,7 +1379,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1379
1379
  add_index "subscribes", ["subscription_id"], name: "index_subscribes_on_subscription_id"
1380
1380
  add_index "subscribes", ["work_id"], name: "index_subscribes_on_work_id"
1381
1381
 
1382
- create_table "subscriptions", force: true do |t|
1382
+ create_table "subscriptions", force: :cascade do |t|
1383
1383
  t.text "title", null: false
1384
1384
  t.text "note"
1385
1385
  t.integer "user_id"
@@ -1393,7 +1393,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1393
1393
  add_index "subscriptions", ["order_list_id"], name: "index_subscriptions_on_order_list_id"
1394
1394
  add_index "subscriptions", ["user_id"], name: "index_subscriptions_on_user_id"
1395
1395
 
1396
- create_table "taggings", force: true do |t|
1396
+ create_table "taggings", force: :cascade do |t|
1397
1397
  t.integer "tag_id"
1398
1398
  t.integer "taggable_id"
1399
1399
  t.string "taggable_type"
@@ -1406,14 +1406,14 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1406
1406
  add_index "taggings", ["tag_id"], name: "index_taggings_on_tag_id"
1407
1407
  add_index "taggings", ["taggable_id", "taggable_type", "context"], name: "index_taggings_on_taggable_id_and_taggable_type_and_context"
1408
1408
 
1409
- create_table "tags", force: true do |t|
1409
+ create_table "tags", force: :cascade do |t|
1410
1410
  t.string "name"
1411
1411
  t.string "name_transcription"
1412
1412
  t.datetime "created_at"
1413
1413
  t.datetime "updated_at"
1414
1414
  end
1415
1415
 
1416
- create_table "use_restrictions", force: true do |t|
1416
+ create_table "use_restrictions", force: :cascade do |t|
1417
1417
  t.string "name", null: false
1418
1418
  t.text "display_name"
1419
1419
  t.text "note"
@@ -1422,7 +1422,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1422
1422
  t.datetime "updated_at"
1423
1423
  end
1424
1424
 
1425
- create_table "user_checkout_stat_transitions", force: true do |t|
1425
+ create_table "user_checkout_stat_transitions", force: :cascade do |t|
1426
1426
  t.string "to_state"
1427
1427
  t.text "metadata", default: "{}"
1428
1428
  t.integer "sort_key"
@@ -1434,7 +1434,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1434
1434
  add_index "user_checkout_stat_transitions", ["sort_key", "user_checkout_stat_id"], name: "index_user_checkout_stat_transitions_on_sort_key_and_stat_id", unique: true
1435
1435
  add_index "user_checkout_stat_transitions", ["user_checkout_stat_id"], name: "index_user_checkout_stat_transitions_on_user_checkout_stat_id"
1436
1436
 
1437
- create_table "user_checkout_stats", force: true do |t|
1437
+ create_table "user_checkout_stats", force: :cascade do |t|
1438
1438
  t.datetime "start_date"
1439
1439
  t.datetime "end_date"
1440
1440
  t.text "note"
@@ -1447,7 +1447,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1447
1447
 
1448
1448
  add_index "user_checkout_stats", ["user_id"], name: "index_user_checkout_stats_on_user_id"
1449
1449
 
1450
- create_table "user_export_file_transitions", force: true do |t|
1450
+ create_table "user_export_file_transitions", force: :cascade do |t|
1451
1451
  t.string "to_state"
1452
1452
  t.text "metadata", default: "{}"
1453
1453
  t.integer "sort_key"
@@ -1459,7 +1459,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1459
1459
  add_index "user_export_file_transitions", ["sort_key", "user_export_file_id"], name: "index_user_export_file_transitions_on_sort_key_and_file_id", unique: true
1460
1460
  add_index "user_export_file_transitions", ["user_export_file_id"], name: "index_user_export_file_transitions_on_file_id"
1461
1461
 
1462
- create_table "user_export_files", force: true do |t|
1462
+ create_table "user_export_files", force: :cascade do |t|
1463
1463
  t.integer "user_id"
1464
1464
  t.string "user_export_file_name"
1465
1465
  t.string "user_export_content_type"
@@ -1470,7 +1470,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1470
1470
  t.datetime "updated_at"
1471
1471
  end
1472
1472
 
1473
- create_table "user_group_has_checkout_types", force: true do |t|
1473
+ create_table "user_group_has_checkout_types", force: :cascade do |t|
1474
1474
  t.integer "user_group_id", null: false
1475
1475
  t.integer "checkout_type_id", null: false
1476
1476
  t.integer "checkout_limit", default: 0, null: false
@@ -1490,7 +1490,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1490
1490
  add_index "user_group_has_checkout_types", ["checkout_type_id"], name: "index_user_group_has_checkout_types_on_checkout_type_id"
1491
1491
  add_index "user_group_has_checkout_types", ["user_group_id"], name: "index_user_group_has_checkout_types_on_user_group_id"
1492
1492
 
1493
- create_table "user_groups", force: true do |t|
1493
+ create_table "user_groups", force: :cascade do |t|
1494
1494
  t.string "name"
1495
1495
  t.text "display_name"
1496
1496
  t.text "note"
@@ -1505,7 +1505,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1505
1505
  t.integer "number_of_time_to_notify_overdue", default: 3, null: false
1506
1506
  end
1507
1507
 
1508
- create_table "user_has_roles", force: true do |t|
1508
+ create_table "user_has_roles", force: :cascade do |t|
1509
1509
  t.integer "user_id"
1510
1510
  t.integer "role_id"
1511
1511
  t.datetime "created_at"
@@ -1515,7 +1515,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1515
1515
  add_index "user_has_roles", ["role_id"], name: "index_user_has_roles_on_role_id"
1516
1516
  add_index "user_has_roles", ["user_id"], name: "index_user_has_roles_on_user_id"
1517
1517
 
1518
- create_table "user_import_file_transitions", force: true do |t|
1518
+ create_table "user_import_file_transitions", force: :cascade do |t|
1519
1519
  t.string "to_state"
1520
1520
  t.text "metadata", default: "{}"
1521
1521
  t.integer "sort_key"
@@ -1527,7 +1527,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1527
1527
  add_index "user_import_file_transitions", ["sort_key", "user_import_file_id"], name: "index_user_import_file_transitions_on_sort_key_and_file_id", unique: true
1528
1528
  add_index "user_import_file_transitions", ["user_import_file_id"], name: "index_user_import_file_transitions_on_user_import_file_id"
1529
1529
 
1530
- create_table "user_import_files", force: true do |t|
1530
+ create_table "user_import_files", force: :cascade do |t|
1531
1531
  t.integer "user_id"
1532
1532
  t.text "note"
1533
1533
  t.datetime "executed_at"
@@ -1545,7 +1545,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1545
1545
  t.integer "default_user_group_id"
1546
1546
  end
1547
1547
 
1548
- create_table "user_import_results", force: true do |t|
1548
+ create_table "user_import_results", force: :cascade do |t|
1549
1549
  t.integer "user_import_file_id"
1550
1550
  t.integer "user_id"
1551
1551
  t.text "body"
@@ -1553,7 +1553,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1553
1553
  t.datetime "updated_at"
1554
1554
  end
1555
1555
 
1556
- create_table "user_reserve_stat_transitions", force: true do |t|
1556
+ create_table "user_reserve_stat_transitions", force: :cascade do |t|
1557
1557
  t.string "to_state"
1558
1558
  t.text "metadata", default: "{}"
1559
1559
  t.integer "sort_key"
@@ -1565,7 +1565,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1565
1565
  add_index "user_reserve_stat_transitions", ["sort_key", "user_reserve_stat_id"], name: "index_user_reserve_stat_transitions_on_sort_key_and_stat_id", unique: true
1566
1566
  add_index "user_reserve_stat_transitions", ["user_reserve_stat_id"], name: "index_user_reserve_stat_transitions_on_user_reserve_stat_id"
1567
1567
 
1568
- create_table "user_reserve_stats", force: true do |t|
1568
+ create_table "user_reserve_stats", force: :cascade do |t|
1569
1569
  t.datetime "start_date"
1570
1570
  t.datetime "end_date"
1571
1571
  t.text "note"
@@ -1578,7 +1578,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1578
1578
 
1579
1579
  add_index "user_reserve_stats", ["user_id"], name: "index_user_reserve_stats_on_user_id"
1580
1580
 
1581
- create_table "users", force: true do |t|
1581
+ create_table "users", force: :cascade do |t|
1582
1582
  t.string "email", default: "", null: false
1583
1583
  t.string "encrypted_password", default: "", null: false
1584
1584
  t.string "reset_password_token"
@@ -1608,7 +1608,7 @@ ActiveRecord::Schema.define(version: 20141014065831) do
1608
1608
  add_index "users", ["unlock_token"], name: "index_users_on_unlock_token", unique: true
1609
1609
  add_index "users", ["username"], name: "index_users_on_username", unique: true
1610
1610
 
1611
- create_table "versions", force: true do |t|
1611
+ create_table "versions", force: :cascade do |t|
1612
1612
  t.string "item_type", null: false
1613
1613
  t.integer "item_id", null: false
1614
1614
  t.string "event", null: false