public
Description: The open source social networking platform in Ruby on Rails from the author of RailsSpace
Homepage: http://insoshi.com
Clone URL: git://github.com/insoshi/insoshi.git
Michael Hartl (author)
Wed Apr 23 20:08:52 -0700 2008
commit  6a531234e43665e34544bff99bce57c684aca63a
tree    af1ec02e275c1be091423044cfbee436c90a3b57
parent  593cafd209abbfb0bc2dc29960f8319d5deb87f7
insoshi / db / migrate / 003_create_communications.rb
100644 26 lines (24 sloc) 0.657 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
class CreateCommunications < ActiveRecord::Migration
  def self.up
    create_table :communications do |t|
      t.string :subject
      t.text :content
      t.string :parent_id
      t.integer :sender_id
      t.integer :recipient_id
      t.datetime :sender_deleted_at
      t.datetime :sender_read_at
      t.datetime :recipient_deleted_at
      t.datetime :recipient_read_at
      t.datetime :replied_at
      t.string :type
      t.timestamps
    end
    add_index :communications, :type
    add_index :communications, :sender_id
    add_index :communications, :recipient_id
  end
 
  def self.down
    drop_table :communications
  end
end