Sha256: 51fa58861712dd7f02875d09fbe838a34ba87a27f9cd8fa35673288160ccd2dd
Contents?: true
Size: 527 Bytes
Versions: 3
Compression:
Stored size: 527 Bytes
Contents
class CreateReserveTransitions < ActiveRecord::Migration def change create_table :reserve_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 :reserve_id t.timestamps end add_index :reserve_transitions, :reserve_id add_index :reserve_transitions, [:sort_key, :reserve_id], unique: true end end
Version data entries
3 entries across 3 versions & 1 rubygems