Guest User

Untitled

a guest
Apr 27th, 2016
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.91 KB | None | 0 0
  1. Rails.application.routes.draw do
  2.  
  3.  
  4. get 'auth/:provider/callback', to: 'sessions#create'
  5. get 'auth/failure', to: redirect('/')
  6. get 'signout', to: 'sessions#destroy', as: 'signout'
  7.  
  8. resources :sessions, only: [:create, :destroy]
  9. resource :home, only: [:show]
  10.  
  11. root to: "home#show"
  12.  
  13.  
  14. resources :submissions
  15. resources :users
  16. # The priority is based upon order of creation: first created -> highest priority.
  17. # See how all your routes lay out with "rake routes".
  18.  
  19. # You can have the root of your site routed with "root"
  20. # root 'application#hello'
  21.  
  22. # Example of regular route:
  23. # get 'products/:id' => 'catalog#view'
  24.  
  25. # Example of named route that can be invoked with purchase_url(id: product.id)
  26. # get 'products/:id/purchase' => 'catalog#purchase', as: :purchase
  27.  
  28. # Example resource route (maps HTTP verbs to controller actions automatically):
  29. # resources :products
  30.  
  31. # Example resource route with options:
  32. # resources :products do
  33. # member do
  34. # get 'short'
  35. # post 'toggle'
  36. # end
  37. #
  38. # collection do
  39. # get 'sold'
  40. # end
  41. # end
  42.  
  43. # Example resource route with sub-resources:
  44. # resources :products do
  45. # resources :comments, :sales
  46. # resource :seller
  47. # end
  48.  
  49. # Example resource route with more complex sub-resources:
  50. # resources :products do
  51. # resources :comments
  52. # resources :sales do
  53. # get 'recent', on: :collection
  54. # end
  55. # end
  56.  
  57. # Example resource route with concerns:
  58. # concern :toggleable do
  59. # post 'toggle'
  60. # end
  61. # resources :posts, concerns: :toggleable
  62. # resources :photos, concerns: :toggleable
  63.  
  64. # Example resource route within a namespace:
  65. # namespace :admin do
  66. # # Directs /admin/products/* to Admin::ProductsController
  67. # # (app/controllers/admin/products_controller.rb)
  68.  
  69. end
Advertisement
Add Comment
Please, Sign In to add comment