aboutsummaryrefslogtreecommitdiffstats
path: root/db/migrate/20120830095442_add_invitable_to_user.rb
blob: a4e72034cb2fb7754b153646b1371cfced453d88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
class AddInvitableToUser < ActiveRecord::Migration
  def change
    change_table :users do |t|
        t.string   :invitation_token, :limit => 60
        t.datetime :invitation_sent_at
        t.datetime :invitation_accepted_at
        t.integer  :invitation_limit
        t.integer  :invited_by_id
        t.string   :invited_by_type

    end

    # Allow null encrypted_password
    change_column :users, :encrypted_password, :string, :null => true
    # Allow null password_salt (add it if you are using Devise's encryptable module)
    #change_column :users, :password_salt, :string, :null => true
  end
end