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

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

Instance Method Summary collapse

Methods included from Schema

#authenticatable, #confirmable, #database_authenticatable, #lockable, #recoverable, #rememberable, #token_authenticatable, #trackable

Instance Method Details

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

Tell how to apply schema methods



17
18
19
20
# File 'lib/devise/orm/mongoid.rb', line 17

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