Created
August 9, 2017 08:59
-
-
Save thomasnaude/871d3dab5495cc21a4a90c6b690a27bf to your computer and use it in GitHub Desktop.
beyound_crud_routes
This file contains 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
Rails.application.routes.draw do | |
resources :restaurants do | |
collection do | |
get 'top', to: 'restaurants#top' | |
end | |
member do | |
get 'chef', to: 'restaurants#chef' | |
end | |
resources :reviews, shallow: :true | |
end | |
namespace :admin do | |
resources :restaurants, only: :index | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment