Sha256: 2f7b4786a2ce9989e047935bc90c6eb967e8f378259123bc3adda94bbb4fe0d3

Contents?: true

Size: 267 Bytes

Versions: 10

Compression:

Stored size: 267 Bytes

Contents

class CreateE9Polls < ActiveRecord::Migration
  def self.up
    create_table :poll_answers, :force => true do |t|
      t.references :poll
      t.integer :votes, :default => 0
      t.text :value
    end
  end

  def self.down
    drop_table :poll_answers
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
e9_polls-1.0.10 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.9 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.8 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.7 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.6 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.5 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.4 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.3 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.2 lib/generators/e9_polls/templates/migration.rb
e9_polls-1.0.1 lib/generators/e9_polls/templates/migration.rb