Skip to content

Commit

Permalink
update dummy migration files
Browse files Browse the repository at this point in the history
  • Loading branch information
nabeta committed Aug 20, 2019
1 parent d3be63d commit b26d617
Show file tree
Hide file tree
Showing 26 changed files with 34 additions and 160 deletions.
2 changes: 0 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ gem 'enju_leaf', github: 'next-l/enju_leaf'
gem 'enju_library', github: 'next-l/enju_library'
gem 'enju_biblio', github: 'next-l/enju_biblio'
gem 'sassc-rails'
gem 'paper_trail'
gem 'paperclip-meta'
group :test do
gem 'rails-controller-testing'
gem 'rspec_junit_formatter'
Expand Down
1 change: 0 additions & 1 deletion spec/dummy/app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ class ApplicationController < ActionController::Base

include EnjuLibrary::Controller
include EnjuBiblio::Controller
before_action :set_paper_trail_whodunnit
after_action :verify_authorized

include Pundit
Expand Down
1 change: 0 additions & 1 deletion spec/dummy/db/migrate/001_create_agents.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ def change
t.text :full_name_transcription
t.text :full_name_alternative
t.timestamps
t.datetime :deleted_at
t.string :zip_code_1
t.string :zip_code_2
t.text :address_1
Expand Down
1 change: 0 additions & 1 deletion spec/dummy/db/migrate/005_create_manifestations.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ def change
t.datetime :date_of_publication
t.datetime :copyright_date
t.timestamps
t.datetime :deleted_at
t.string :access_address
t.integer :language_id, default: 1, null: false
t.integer :carrier_type_id, default: 1, null: false
Expand Down
1 change: 0 additions & 1 deletion spec/dummy/db/migrate/006_create_items.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ def change
t.string :call_number
t.string :item_identifier
t.timestamps
t.datetime :deleted_at
t.integer :shelf_id, default: 1, null: false
t.boolean :include_supplements, default: false, null: false
t.text :note
Expand Down
2 changes: 0 additions & 2 deletions spec/dummy/db/migrate/059_create_libraries.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ class CreateLibraries < ActiveRecord::Migration[5.2]
def change
create_table :libraries do |t|
t.string :name, index: true, null: false
t.text :display_name
t.string :short_display_name, null: false
t.string :zip_code
t.text :street
Expand All @@ -20,7 +19,6 @@ def change
t.references :country

t.timestamps
t.datetime :deleted_at
end
end
end
2 changes: 0 additions & 2 deletions spec/dummy/db/migrate/069_create_shelves.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,11 @@ class CreateShelves < ActiveRecord::Migration[5.2]
def change
create_table :shelves do |t|
t.string :name, null: false
t.text :display_name
t.text :note
t.references :library, index: true, null: false
t.integer :items_count, default: 0, null: false
t.integer :position
t.timestamps
t.datetime :deleted_at
end
end
end
2 changes: 0 additions & 2 deletions spec/dummy/db/migrate/077_create_user_groups.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@ class CreateUserGroups < ActiveRecord::Migration[5.2]
def change
create_table :user_groups do |t|
t.string :name, not_null: true
t.text :display_name
t.text :note
t.integer :position
t.timestamps
t.datetime :deleted_at
end
end
end
1 change: 0 additions & 1 deletion spec/dummy/db/migrate/080_create_library_groups.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ class CreateLibraryGroups < ActiveRecord::Migration[5.2]
def change
create_table :library_groups do |t|
t.string :name, null: false
t.text :display_name
t.string :short_name, index: true, null: false
t.text :my_networks
t.text :login_banner
Expand Down
1 change: 0 additions & 1 deletion spec/dummy/db/migrate/124_create_bookstores.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ def change
t.string :fax_number
t.string :url
t.integer :position
t.datetime :deleted_at

t.timestamps
end
Expand Down
6 changes: 2 additions & 4 deletions spec/dummy/db/migrate/125_create_donates.rb
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
class CreateDonates < ActiveRecord::Migration[5.2]
def change
create_table :donates do |t|
t.integer :agent_id, null: false
t.integer :item_id, null: false
t.references :agent, foreign_key: true, null: false
t.references :item, foreign_key: true, null: false

t.timestamps
end
add_index :donates, :agent_id
add_index :donates, :item_id
end
end
3 changes: 1 addition & 2 deletions spec/dummy/db/migrate/20081006090811_create_subscriptions.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@ def change
create_table :subscriptions do |t|
t.text :title, null: false
t.text :note
t.references :user, index: true
t.references :user, foreign_key: true
t.references :order_list, index: true
t.datetime :deleted_at
t.integer :subscribes_count, default: 0, null: false

t.timestamps
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ class CreateSearchEngines < ActiveRecord::Migration[5.2]
def change
create_table :search_engines do |t|
t.string :name, null: false
t.text :display_name
t.string :url, null: false
t.text :base_url, null: false
t.text :http_method, null: false
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,11 @@
class CreateAgentImportFiles < ActiveRecord::Migration[5.2]
def change
create_table :agent_import_files do |t|
t.integer :parent_id
t.string :content_type
t.integer :size
t.integer :user_id
t.references :user, foreign_key: true
t.text :note
t.datetime :executed_at
t.string :agent_import_file_name
t.string :agent_import_content_type
t.integer :agent_import_file_size
t.datetime :agent_import_updated_at

t.timestamps
end
add_index :agent_import_files, :parent_id
add_index :agent_import_files, :user_id
end
end
Original file line number Diff line number Diff line change
@@ -1,20 +1,11 @@
class CreateResourceImportFiles < ActiveRecord::Migration[5.2]
def change
create_table :resource_import_files do |t|
t.integer :parent_id
t.string :content_type
t.integer :size
t.integer :user_id
t.references :user, foreign_key: true
t.text :note
t.datetime :executed_at
t.string :resource_import_file_name
t.string :resource_import_content_type
t.integer :resource_import_file_size
t.datetime :resource_import_updated_at

t.timestamps
end
add_index :resource_import_files, :parent_id
add_index :resource_import_files, :user_id
end
end

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,11 @@ class CreateImportRequests < ActiveRecord::Migration[5.2]
def change
create_table :import_requests do |t|
t.string :isbn
t.integer :manifestation_id
t.integer :user_id
t.references :manifestation, foreign_key: true
t.references :user, foreign_key: true

t.timestamps
end
add_index :import_requests, :isbn
add_index :import_requests, :manifestation_id
add_index :import_requests, :user_id
end
end

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
class AddAdditionalAttributesToUser < ActiveRecord::Migration[5.2]
def change
add_column :users, :username, :string
add_column :users, :deleted_at, :datetime
add_column :users, :expired_at, :datetime

add_column :users, :failed_attempts, :integer, default: 0
Expand Down
6 changes: 2 additions & 4 deletions spec/dummy/db/migrate/20130506175834_create_identifiers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,12 @@ class CreateIdentifiers < ActiveRecord::Migration[5.2]
def change
create_table :identifiers do |t|
t.string :body, null: false
t.integer :identifier_type_id, null: false
t.integer :manifestation_id
t.references :identifier_type, foreign_key: true, null: false
t.references :manifestation, foreign_key: true, null: false
t.boolean :primary
t.integer :position

t.timestamps
end
add_index :identifiers, [:body, :identifier_type_id]
add_index :identifiers, :manifestation_id
end
end
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
class CreateUserImportFiles < ActiveRecord::Migration[5.2]
def change
create_table :user_import_files do |t|
t.references :user, index: true
t.references :user, foreign_key: true
t.text :note
t.datetime :executed_at
t.string :user_import_file_name
t.string :user_import_content_type
t.integer :user_import_file_size
t.datetime :user_import_updated_at
t.string :user_import_fingerprint
t.string :edit_mode
t.text :error_message
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
class CreateResourceExportFiles < ActiveRecord::Migration[5.2]
def change
create_table :resource_export_files do |t|
t.integer :user_id
t.attachment :resource_export
t.references :user
t.datetime :executed_at

t.timestamps
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
class CreateUserExportFiles < ActiveRecord::Migration[5.2]
def change
create_table :user_export_files do |t|
t.references :user, index: true
t.attachment :user_export
t.references :user, foreign_key: true
t.datetime :executed_at

t.timestamps
Expand Down

This file was deleted.

This file was deleted.

Loading

0 comments on commit b26d617

Please sign in to comment.