Module: Unidom::Visitor::Concerns::AsVisitor::ClassMethods

Defined in:
app/models/unidom/visitor/concerns/as_visitor.rb

Instance Method Summary collapse

Instance Method Details

#sign_up!(it, as: nil, through: nil, at: Time.now, flag_code: 'RQRD', primary: true) ⇒ Object



58
59
60
61
62
63
64
# File 'app/models/unidom/visitor/concerns/as_visitor.rb', line 58

def sign_up!(it, as: nil, through: nil, at: Time.now, flag_code: 'RQRD', primary: true)
  user = create! opened_at: at
  user.cognize! it,      primary: true,    at: at
  user.is_identificated! as:      as,      at: at
  user.is_authenticated! through: through, at: at
  user
end