From bf9418957e0eb7e17ad992fbb890e0bb91743b51 Mon Sep 17 00:00:00 2001 From: Frederik Ramm Date: Wed, 26 Sep 2007 15:48:00 +0000 Subject: [PATCH] new calls --- config/routes.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/routes.rb b/config/routes.rb index a1ddb4f49..bf1f2a20f 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -3,6 +3,7 @@ ActionController::Routing::Routes.draw do |map| # API map.connect "api/#{API_VERSION}/node/create", :controller => 'node', :action => 'create' map.connect "api/#{API_VERSION}/node/:id/ways", :controller => 'way', :action => 'ways_for_node', :id => /\d+/ + map.connect "api/#{API_VERSION}/node/:id/relations", :controller => 'relation', :action => 'relations_for_node', :id => /\d+/ map.connect "api/#{API_VERSION}/node/:id/history", :controller => 'old_node', :action => 'history', :id => /\d+/ map.connect "api/#{API_VERSION}/node/:id", :controller => 'node', :action => 'read', :id => /\d+/, :conditions => { :method => :get } map.connect "api/#{API_VERSION}/node/:id", :controller => 'node', :action => 'update', :id => /\d+/, :conditions => { :method => :put } @@ -12,6 +13,7 @@ ActionController::Routing::Routes.draw do |map| map.connect "api/#{API_VERSION}/way/create", :controller => 'way', :action => 'create' map.connect "api/#{API_VERSION}/way/:id/history", :controller => 'old_way', :action => 'history', :id => /\d+/ map.connect "api/#{API_VERSION}/way/:id/full", :controller => 'way', :action => 'full', :id => /\d+/ + map.connect "api/#{API_VERSION}/way/:id/relations", :controller => 'relation', :action => 'relations_for_way', :id => /\d+/ map.connect "api/#{API_VERSION}/way/:id", :controller => 'way', :action => 'read', :id => /\d+/, :conditions => { :method => :get } map.connect "api/#{API_VERSION}/way/:id", :controller => 'way', :action => 'update', :id => /\d+/, :conditions => { :method => :put } map.connect "api/#{API_VERSION}/way/:id", :controller => 'way', :action => 'delete', :id => /\d+/, :conditions => { :method => :delete } @@ -19,6 +21,7 @@ ActionController::Routing::Routes.draw do |map| map.connect "api/#{API_VERSION}/capabilities", :controller => 'api', :action => 'capabilities' map.connect "api/#{API_VERSION}/relation/create", :controller => 'relation', :action => 'create' + map.connect "api/#{API_VERSION}/relation/:id/relations", :controller => 'relation', :action => 'relations_for_relation', :id => /\d+/ map.connect "api/#{API_VERSION}/relation/:id/history", :controller => 'old_relation', :action => 'history', :id => /\d+/ map.connect "api/#{API_VERSION}/relation/:id/full", :controller => 'relation', :action => 'full', :id => /\d+/ map.connect "api/#{API_VERSION}/relation/:id", :controller => 'relation', :action => 'read', :id => /\d+/, :conditions => { :method => :get } @@ -32,6 +35,7 @@ ActionController::Routing::Routes.draw do |map| map.connect "api/#{API_VERSION}/search", :controller => 'search', :action => 'search_all' map.connect "api/#{API_VERSION}/ways/search", :controller => 'search', :action => 'search_ways' + map.connect "api/#{API_VERSION}/relations/search", :controller => 'search', :action => 'search_relations' map.connect "api/#{API_VERSION}/nodes/search", :controller => 'search', :action => 'search_nodes' map.connect "api/#{API_VERSION}/user/details", :controller => 'user', :action => 'api_details' -- 2.43.2