Created
September 5, 2012 23:41
-
-
Save takuyan/3647800 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ==== Examples | |
# | |
# Let's say you have an User model configured to use authenticatable, | |
# confirmable and recoverable modules. After creating this inside your routes: | |
# | |
devise_for :users | |
# | |
# This method is going to look inside your User model and create the | |
# needed routes: | |
# | |
# Session routes for Authenticatable (default) | |
new_user_session GET /users/sign_in {:controller=>"devise/sessions", :action=>"new"} | |
user_session POST /users/sign_in {:controller=>"devise/sessions", :action=>"create"} | |
destroy_user_session DELETE /users/sign_out {:controller=>"devise/sessions", :action=>"destroy"} | |
# Password routes for Recoverable, if User model has :recoverable configured | |
new_user_password GET /users/password/new(.:format) {:controller=>"devise/passwords", :action=>"new"} | |
edit_user_password GET /users/password/edit(.:format) {:controller=>"devise/passwords", :action=>"edit"} | |
user_password PUT /users/password(.:format) {:controller=>"devise/passwords", :action=>"update"} | |
POST /users/password(.:format) {:controller=>"devise/passwords", :action=>"create"} | |
# Confirmation routes for Confirmable, if User model has :confirmable configured | |
new_user_confirmation GET /users/confirmation/new(.:format) {:controller=>"devise/confirmations", :action=>"new"} | |
user_confirmation GET /users/confirmation(.:format) {:controller=>"devise/confirmations", :action=>"show"} | |
POST /users/confirmation(.:format) {:controller=>"devise/confirmations", :action=>"create"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment