Sha256: 39e9dd7d455cb13c27de7ca6b7493735cebe93e776b753c326011a9494190b0b
Contents?: true
Size: 437 Bytes
Versions: 2
Compression:
Stored size: 437 Bytes
Contents
class CreateComments < ActiveRecord::Migration def self.up create_table :comments do |t| t.string :title, :limit => 50 t.text :comment t.references :commentable, :polymorphic => true t.references :user t.timestamps end add_index :comments, :commentable_type add_index :comments, :commentable_id add_index :comments, :user_id end def self.down drop_table :comments end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
solidus_comments-1.0.1 | db/migrate/20091021182639_create_comments.rb |
solidus_comments-1.0.0 | db/migrate/20091021182639_create_comments.rb |