Sha256: 2fe8d0dcc33e8c2487dcfca5451631789c485aea2e3cd091db41dae573d1b789

Contents?: true

Size: 366 Bytes

Versions: 7

Compression:

Stored size: 366 Bytes

Contents

class CreateHeaders < ActiveRecord::Migration
  def self.up
    create_table :headers do |t|
      t.string    :headerable_type, limit: 30, null: false
      t.integer   :headerable_id, null: false
      
      t.timestamps
    end
    
    add_index :headers, [:headerable_type, :headerable_id], unique: true
  end

  def self.down
    drop_table :headers
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
ab_admin-0.3.6 db/migrate/20130101000004_create_headers.rb
ab_admin-0.3.5 db/migrate/20130101000004_create_headers.rb
ab_admin-0.3.4 db/migrate/20130101000004_create_headers.rb
ab_admin-0.3.3 db/migrate/20130101000004_create_headers.rb
ab_admin-0.3.2 db/migrate/20130101000004_create_headers.rb
ab_admin-0.3.1 db/migrate/20130101000004_create_headers.rb
ab_admin-0.3.0 db/migrate/20130101000004_create_headers.rb