X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/7a4115f090c6a6f923b2fe31b505982ac006e992..fc13e29d81b877b1c35b6616ab4eb5423b199ce6:/config/routes.rb diff --git a/config/routes.rb b/config/routes.rb index 7ecb200da..3ede0d33d 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -186,7 +186,7 @@ OpenStreetMap::Application.routes.draw do post "/user/new" => "users#create" get "/user/terms" => "users#terms" post "/user/save" => "users#save" - get "/user/:display_name/confirm/resend" => "confirmations#confirm_resend", :as => :user_confirm_resend + post "/user/:display_name/confirm/resend" => "confirmations#confirm_resend", :as => :user_confirm_resend match "/user/:display_name/confirm" => "confirmations#confirm", :via => [:get, :post] match "/user/confirm" => "confirmations#confirm", :via => [:get, :post] match "/user/confirm-email" => "confirmations#confirm_email", :via => [:get, :post] @@ -273,6 +273,7 @@ OpenStreetMap::Application.routes.draw do resource :role, :controller => "user_roles", :path => "roles/:role", :only => [:create, :destroy] scope :module => :users do resource :issued_blocks, :path => "blocks_by", :only => :show + resource :received_blocks, :path => "blocks", :only => [:show, :edit, :destroy] end end get "/user/:display_name/account", :to => redirect(:path => "/account/edit") @@ -310,16 +311,16 @@ OpenStreetMap::Application.routes.draw do get "/export/embed" => "export#embed" # messages - resources :messages, :only => [:create, :show, :destroy] do + resources :messages, :id => /\d+/, :only => [:create, :show, :destroy] do post :mark patch :unmute match :reply, :via => [:get, :post] - collection do - get :inbox - get :muted - get :outbox - end + end + namespace :messages, :path => "/messages" do + resource :inbox, :only => :show + resource :muted_inbox, :path => "muted", :only => :show + resource :outbox, :only => :show end get "/user/:display_name/inbox", :to => redirect(:path => "/messages/inbox") get "/user/:display_name/outbox", :to => redirect(:path => "/messages/outbox") @@ -333,9 +334,7 @@ OpenStreetMap::Application.routes.draw do resources :user_mutes, :only => [:index] # banning pages - get "/user/:display_name/blocks" => "user_blocks#blocks_on", :as => "user_blocks_on" resources :user_blocks, :path_names => { :new => "new/:display_name" } - match "/user/:display_name/blocks/revoke_all" => "user_blocks#revoke_all", :via => [:get, :post], :as => "revoke_all_user_blocks" # issues and reports resources :issues do