Sha256: da6eaf352e5f8be51bf17b63deb684399f79e3ba262a427e10d9d7062fd50520
Contents?: true
Size: 728 Bytes
Versions: 5
Compression:
Stored size: 728 Bytes
Contents
class DeviseCreate<%= table_name.camelize %> < ActiveRecord::Migration def self.up create_table(:<%= table_name %>) do |t| t.string :email, :null => :false t.string :omniauth_uid, :null => false # t.rememberable # t.trackable # t.confirmable # t.token_authenticatable <% for attribute in attributes -%> t.<%= attribute.type %> :<%= attribute.name %> <% end -%> t.timestamps end add_index :<%= table_name %>, :email, :unique => true add_index :<%= table_name %>, :omniauth_uid, :unique => true # add_index :<%= table_name %>, :authentication_token, :unique => true end def self.down drop_table :<%= table_name %> end end
Version data entries
5 entries across 5 versions & 1 rubygems