Class: Spree::UserRegistrationsController

Inherits:
Devise::RegistrationsController
  • Object
show all
Includes:
Core::ControllerHelpers, SslRequirement
Defined in:
app/controllers/spree/user_registrations_controller.rb

Instance Method Summary collapse

Instance Method Details

#cancelObject

GET /resource/cancel Forces the session data which is usually expired after sign in to be expired now. This is useful if the user wants to cancel oauth signing in/up in the middle of the process, removing all OAuth session data.



54
55
56
# File 'app/controllers/spree/user_registrations_controller.rb', line 54

def cancel
  super
end

#createObject

POST /resource/sign_up



20
21
22
23
24
25
26
27
28
29
30
31
32
# File 'app/controllers/spree/user_registrations_controller.rb', line 20

def create
  @user = build_resource(params[:user])
  if resource.save
    set_flash_message(:notice, :signed_up)
    (:user, @user)
    session[:spree_user_signup] = true
    associate_user
    (:user, @user)
  else
    clean_up_passwords(resource)
    render :new
  end
end

#destroyObject

DELETE /resource



45
46
47
# File 'app/controllers/spree/user_registrations_controller.rb', line 45

def destroy
  super
end

#editObject

GET /resource/edit



35
36
37
# File 'app/controllers/spree/user_registrations_controller.rb', line 35

def edit
  super
end

#newObject

GET /resource/sign_up



15
16
17
# File 'app/controllers/spree/user_registrations_controller.rb', line 15

def new
  super
end

#updateObject

PUT /resource



40
41
42
# File 'app/controllers/spree/user_registrations_controller.rb', line 40

def update
  super
end