refactored routes file:
now using namespaces to make the file more readable and better structured
This commit is contained in:
parent
6bc24a48f0
commit
ae6a202e59
@ -2,24 +2,36 @@ Rails.application.routes.draw do
|
||||
|
||||
devise_for :users, path_names: {sign_in: 'log_in', sign_out: 'log out'}
|
||||
|
||||
get 'login/index'
|
||||
namespace :login do
|
||||
get 'index'
|
||||
end
|
||||
|
||||
get 'tiss_crawler/search'
|
||||
namespace :tiss_crawler do
|
||||
get 'search'
|
||||
end
|
||||
|
||||
get 'people_crawler/show_basic'
|
||||
get 'people_crawler/show_detail'
|
||||
post 'people_crawler/show_detail'
|
||||
get 'people_crawler/add_to_fav'
|
||||
post 'people_crawler/add_to_fav'
|
||||
namespace :people_crawler do
|
||||
get 'show_basic'
|
||||
get 'show_detail'
|
||||
post 'show_detail'
|
||||
get 'add_to_fav'
|
||||
post 'add_to_fav'
|
||||
end
|
||||
|
||||
get 'courses_crawler/show_basic'
|
||||
get 'courses_crawler/show_detail'
|
||||
post 'courses_crawler/show_detail'
|
||||
get 'courses_crawler/add_to_fav'
|
||||
post 'courses_crawler/add_to_fav'
|
||||
namespace :courses_crawler do
|
||||
get 'show_basic'
|
||||
get 'show_detail'
|
||||
post 'show_detail'
|
||||
get 'add_to_fav'
|
||||
post 'add_to_fav'
|
||||
end
|
||||
|
||||
namespace :favorites do
|
||||
get 'favorite_person/index'
|
||||
get 'index'
|
||||
get 'people'
|
||||
get 'courses'
|
||||
get 'theses'
|
||||
get 'projects'
|
||||
end
|
||||
|
||||
# For details on the DSL available within this file, see https://guides.rubyonrails.org/routing.html
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user