X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/b4106383d99ccbf152d79b0f2c9deca95df9fb61..b745126b6ecf679fb43de65d571e44a149dfc7f6:/config/routes.rb?ds=sidebyside diff --git a/config/routes.rb b/config/routes.rb index 0522115f1..4b126c752 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -208,11 +208,12 @@ OpenStreetMap::Application.routes.draw do get "/traces/mine/tag/:tag" => "traces#mine" get "/traces/mine/page/:page" => "traces#mine" get "/traces/mine" => "traces#mine" - resources :traces, :only => [:new, :create] + resources :traces, :only => [:new, :create, :edit, :update] post "/trace/create" => "traces#create" # remove after deployment get "/trace/create", :to => redirect(:path => "/traces/new") get "/trace/:id/data" => "traces#data", :id => /\d+/, :as => "trace_data" - match "/trace/:id/edit" => "traces#edit", :via => [:get, :post], :id => /\d+/, :as => "trace_edit" + post "trace/:id/edit" => "traces#update" # remove after deployment + get "/trace/:id/edit", :to => redirect(:path => "/traces/%{id}/edit") post "/trace/:id/delete" => "traces#delete", :id => /\d+/ # diary pages @@ -313,4 +314,9 @@ OpenStreetMap::Application.routes.draw do # redactions resources :redactions + + # errors + match "/403", :to => "errors#forbidden", :via => :all + match "/404", :to => "errors#not_found", :via => :all + match "/500", :to => "errors#internal_server_error", :via => :all end