Last active
April 5, 2016 22:06
-
-
Save peterxjang/c46ca17ec1fc7a4019774ebba84c257c to your computer and use it in GitHub Desktop.
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 | |
namespace :api do | |
namespace :v1 do | |
get '/employees' => 'employees#index' | |
get '/employees/:id' => 'employees#show' | |
post '/employees' => 'employees#create' | |
patch '/employees/:id' => 'employees#update' | |
delete '/employees/:id' => 'employees#destroy' | |
end | |
namespace :v2 do | |
get '/employees' => 'employees#index' | |
get '/employees/:id' => 'employees#show' | |
post '/employees' => 'employees#create' | |
patch '/employees/:id' => 'employees#update' | |
delete '/employees/:id' => 'employees#destroy' | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment