Map 'full' to api way show action
This commit is contained in:
parent
51dab659f5
commit
0f2aa939d4
8 changed files with 58 additions and 44 deletions
|
@ -37,7 +37,6 @@ OpenStreetMap::Application.routes.draw do
|
|||
get "node/:id/:version" => "old_nodes#show", :as => :api_old_node, :id => /\d+/, :version => /\d+/
|
||||
|
||||
get "way/:id/history" => "old_ways#history", :as => :api_way_history, :id => /\d+/
|
||||
get "way/:id/full" => "ways#full", :as => :way_full, :id => /\d+/
|
||||
get "way/:id/relations" => "relations#relations_for_way", :as => :way_relations, :id => /\d+/
|
||||
post "way/:id/:version/redact" => "old_ways#redact", :as => :way_version_redact, :version => /\d+/, :id => /\d+/
|
||||
get "way/:id/:version" => "old_ways#show", :as => :api_old_way, :id => /\d+/, :version => /\d+/
|
||||
|
@ -55,7 +54,11 @@ OpenStreetMap::Application.routes.draw do
|
|||
put "node/create" => "nodes#create", :as => nil
|
||||
|
||||
resources :ways, :only => [:index, :create]
|
||||
resources :ways, :path => "way", :id => /\d+/, :only => [:show, :update, :destroy]
|
||||
resources :ways, :path => "way", :id => /\d+/, :only => [:show, :update, :destroy] do
|
||||
member do
|
||||
get :full, :action => :show, :full => true, :as => nil
|
||||
end
|
||||
end
|
||||
put "way/create" => "ways#create", :as => nil
|
||||
|
||||
resources :relations, :only => [:index, :create]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue