Sha256: ef34dcf5e3cf3fb02f714531e7a736ac825297d03c0b15c786e89da5ba60adaf

Contents?: true

Size: 711 Bytes

Versions: 238

Compression:

Stored size: 711 Bytes

Contents

class CreateUserExportFileTransitions < ActiveRecord::Migration
  def change
    create_table :user_export_file_transitions do |t|
      t.string :to_state
      if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
        t.text :metadata
      else
        t.text :metadata, default: "{}"
      end
      t.integer :sort_key
      t.integer :user_export_file_id
      t.timestamps
    end

    add_index :user_export_file_transitions, :user_export_file_id, name: "index_user_export_file_transitions_on_file_id"
    add_index :user_export_file_transitions, [:sort_key, :user_export_file_id], unique: true, name: "index_user_export_file_transitions_on_sort_key_and_file_id"
  end
end

Version data entries

238 entries across 235 versions & 22 rubygems

Version Path
enju_biblio-0.2.4 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_subject-0.2.3 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_manifestation_viewer-0.2.2 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_message-0.2.3 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_event-0.2.2 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_circulation-0.2.4 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_nii-0.2.1 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_subject-0.2.2 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_circulation-0.2.3 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_message-0.2.2 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_biblio-0.2.3 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_grid-0.2.0 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_biblio-0.2.2 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_manifestation_viewer-0.2.1 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_circulation-0.2.2 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_event-0.2.1 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_message-0.2.1 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_subject-0.2.1 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_leaf-1.2.1 spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb
enju_leaf-1.2.1 vendor/bundle/ruby/2.3/gems/enju_biblio-0.2.0/spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb