Sha256: 8a47077afef8b34f0a7d72884b6a31245641e400b0cfbff0afb8469a19e15414

Contents?: true

Size: 648 Bytes

Versions: 17

Compression:

Stored size: 648 Bytes

Contents

class CreateImportRequestTransitions < ActiveRecord::Migration[4.2]
  def change
    create_table :import_request_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 :import_request_id
      t.timestamps
    end

    add_index :import_request_transitions, :import_request_id
    add_index :import_request_transitions, %i[sort_key import_request_id], unique: true, name: "index_import_request_transitions_on_sort_key_and_request_id"
  end
end

Version data entries

17 entries across 17 versions & 2 rubygems

Version Path
enju_leaf-1.3.6 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.5 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.4 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.4.rc.2 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.4.rc.1 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.3.1 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.3 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_manifestation_viewer-0.3.3 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.2 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_manifestation_viewer-0.3.2 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.1 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_manifestation_viewer-0.3.1 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.0 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_manifestation_viewer-0.3.0 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_leaf-1.3.0.rc.1 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_manifestation_viewer-0.3.0.rc.1 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb
enju_manifestation_viewer-0.3.0.beta.2 spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb