collab/db/migrate/20100305002309_clearance_create_users.rb

22 lines
599 B
Ruby
Raw Normal View History

2010-03-05 06:48:00 +00:00
class ClearanceCreateUsers < ActiveRecord::Migration
def self.up
create_table(:users) do |t|
t.string :email
t.string :encrypted_password, :limit => 128
t.string :salt, :limit => 128
t.string :confirmation_token, :limit => 128
t.string :remember_token, :limit => 128
t.boolean :email_confirmed, :default => false, :null => false
t.timestamps
end
add_index :users, [:id, :confirmation_token]
add_index :users, :email
add_index :users, :remember_token
end
def self.down
drop_table :users
end
end