Sha256: a78d4f754295f62f457fdb5ca51b519dbdb4bf8e10e1cd5f1825776f1d1ea353

Contents?: true

Size: 373 Bytes

Versions: 7

Compression:

Stored size: 373 Bytes

Contents

class CreateMessages < ActiveRecord::Migration
  def self.up
    create_table :messages do |t|
      t.references :sender, :polymorphic => true, :null => false
      t.text :subject
      t.text :body
      t.string :state, :null => false
      t.datetime :hidden_at
      t.string :type
      t.timestamps
    end
  end

  def self.down
    drop_table :messages
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
has_messages-0.3.0 db/migrate/001_create_messages.rb
has_messages-0.1.0 db/migrate/001_create_messages.rb
has_messages-0.1.1 db/migrate/001_create_messages.rb
has_messages-0.1.2 db/migrate/001_create_messages.rb
has_messages-0.1.3 db/migrate/001_create_messages.rb
has_messages-0.2.0 db/migrate/001_create_messages.rb
has_messages-0.3.1 db/migrate/001_create_messages.rb