Class: Clearance::UsersController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/clearance/users_controller.rb

Instance Method Summary collapse

Instance Method Details

#createObject

Here the email login users are created, FB user creation is managed in the fb controller



14
15
16
17
18
19
20
21
22
23
24
# File 'app/controllers/clearance/users_controller.rb', line 14

def create
  @user = ::User.new params[:user]
  if @user.save
    flash_notice_after_create
    (@user) #Login recently created user
    redirect_to(url_after_create)
  else
    flash_failure_after_create
    render :template => 'users/new'
  end
end

#newObject



8
9
10
11
# File 'app/controllers/clearance/users_controller.rb', line 8

def new
  @user = ::User.new(params[:user])
  render :template => 'users/new'
end