Sha256: 193257579470c01dbe3d22f89debbe932f35762f723d665a101bd6a3bbe7dd44

Contents?: true

Size: 433 Bytes

Versions: 5

Compression:

Stored size: 433 Bytes

Contents

class IsGraffitiableMigration < ActiveRecord::Migration
  def self.up
    create_table :graffitis do |t|
      t.string :name, :default => ''
      t.string :value, :default => ''
      t.string  :graffitiable_type, :default => ''
      t.integer :graffitiable_id
      t.timestamps
    end
    
    add_index :graffitis,     [:name, :graffitiable_id, :graffitiable_type]
  end
  
  def self.down
    drop_table :graffitis
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
is_graffitiable-0.1.4 generators/is_graffitiable_migration/templates/migration.rb
is_graffitiable-0.1.3 generators/is_graffitiable_migration/templates/migration.rb
is_graffitiable-0.1.2 generators/is_graffitiable_migration/templates/migration.rb
is_graffitiable-0.1.1 generators/is_graffitiable_migration/templates/migration.rb
is_graffitiable-0.1.0 generators/is_graffitiable_migration/templates/migration.rb