Module: Devise::Orm::Mongoid::Schema

Includes:
Schema
Defined in:
lib/devise/orm/mongoid.rb

Instance Method Summary collapse

Methods included from Schema

#confirmable, #database_authenticatable, #encryptable, #lockable, #reconfirmable, #recoverable, #rememberable, #token_authenticatable, #trackable

Instance Method Details

#apply_devise_schema(name, type, options = {}) ⇒ Object

Tell how to apply schema methods



19
20
21
22
# File 'lib/devise/orm/mongoid.rb', line 19

def apply_devise_schema(name, type, options={})
  type = Time if type == DateTime
  field name, { :type => type }.merge!(options)
end