2012-01-30 20:39:34 +00:00
|
|
|
# -*- encoding : utf-8 -*-
|
2011-12-19 15:30:14 +00:00
|
|
|
class CreateComments < ActiveRecord::Migration
|
|
|
|
def self.up
|
|
|
|
create_table :comments do |t|
|
|
|
|
t.integer :commentable_id
|
|
|
|
t.string :commentable_type
|
|
|
|
t.integer :user_id
|
|
|
|
t.text :body
|
|
|
|
|
|
|
|
t.timestamps
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
def self.down
|
|
|
|
drop_table :comments
|
|
|
|
end
|
|
|
|
end
|