summaryrefslogtreecommitdiffstats
path: root/config/routes.rb
diff options
context:
space:
mode:
authorGo MAEDA <maeda@farend.jp>2021-04-15 00:32:44 +0000
committerGo MAEDA <maeda@farend.jp>2021-04-15 00:32:44 +0000
commite65980dc0995ee94f399f2d7e0d1b56b8ac6af57 (patch)
treedf4625522b8260fed339d7da6c108c88cc4c241c /config/routes.rb
parentf2b17f77943959ea2a415f239ff50e2758c49859 (diff)
downloadredmine-e65980dc0995ee94f399f2d7e0d1b56b8ac6af57.tar.gz
redmine-e65980dc0995ee94f399f2d7e0d1b56b8ac6af57.zip
Use named routes in base layout and account sidebar (#35075).
Patch by Jan Schulz-Hofen. git-svn-id: http://svn.redmine.org/redmine/trunk@20944 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'config/routes.rb')
-rw-r--r--config/routes.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/config/routes.rb b/config/routes.rb
index be12e504e..dbcd8ddc7 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -83,7 +83,7 @@ Rails.application.routes.draw do
match '/imports/:id/run', :to => 'imports#run', :via => [:get, :post], :as => 'import_run'
match 'my/account', :controller => 'my', :action => 'account', :via => [:get, :put]
- match 'my/account/destroy', :controller => 'my', :action => 'destroy', :via => [:get, :post]
+ match 'my/account/destroy', :controller => 'my', :action => 'destroy', :via => [:get, :post], :as => :delete_my_account
match 'my/page', :controller => 'my', :action => 'page', :via => :get
post 'my/page', :to => 'my#update_page'
match 'my', :controller => 'my', :action => 'index', :via => :get # Redirects to my/page
@@ -349,8 +349,7 @@ Rails.application.routes.draw do
resources :enumerations, :except => :show
match 'enumerations/:type', :to => 'enumerations#index', :via => :get
- get 'projects/:id/search', :controller => 'search', :action => 'index'
- get 'search', :controller => 'search', :action => 'index'
+ get '(projects/:id)/search', :controller => 'search', :action => 'index', :as => 'search'
get 'mail_handler', :to => 'mail_handler#new'