sms-pager/db/migrate/20151008022535_sorcery_init.rb

20 lines
621 B
Ruby
Raw Normal View History

2015-10-07 22:03:31 -05:00
class SorceryInit < ActiveRecord::Migration
def change
change_column :people, :email, :string, null: false
add_index :people, :email, unique: true
add_column :people, :activation_state, :string, default: nil
add_column :people, :activation_token, :string, default: nil
add_column :people, :activation_token_expires_at, :datetime, default: nil
add_index :people, :activation_token
create_table :authentications do |t|
t.integer :person_id, null: false
t.string :provider, :uid, null: false
t.timestamps
end
add_index :authentications, [:provider, :uid]
end
end