Moved bulk_edit/update routes into issues resources.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8148 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2011-12-10 08:45:52 +00:00
parent 8d6af1fcb0
commit ac6e404547
2 changed files with 2 additions and 4 deletions

View File

@ -44,8 +44,6 @@ ActionController::Routing::Routes.draw do |map|
map.preview_issue '/issues/preview/:id', :controller => 'previews', :action => 'issue' # TODO: would look nicer as /issues/:id/preview
map.issues_context_menu '/issues/context_menu', :controller => 'context_menus', :action => 'issues'
map.issue_changes '/issues/changes', :controller => 'journals', :action => 'index'
map.bulk_edit_issue 'issues/bulk_edit', :controller => 'issues', :action => 'bulk_edit', :conditions => { :method => :get }
map.bulk_update_issue 'issues/bulk_edit', :controller => 'issues', :action => 'bulk_update', :conditions => { :method => :post }
map.quoted_issue '/issues/:id/quoted', :controller => 'journals', :action => 'new', :id => /\d+/, :conditions => { :method => :post }
map.connect '/issues/:id/destroy', :controller => 'issues', :action => 'destroy', :conditions => { :method => :post } # legacy
@ -65,7 +63,7 @@ ActionController::Routing::Routes.draw do |map|
reports.connect 'projects/:id/issues/report/:detail', :action => 'issue_report_details'
end
map.resources :issues do |issues|
map.resources :issues, :collection => {:bulk_edit => :get, :bulk_update => :post} do |issues|
issues.resources :time_entries, :controller => 'timelog', :collection => {:report => :get}
issues.resources :relations, :shallow => true, :controller => 'issue_relations', :only => [:index, :show, :create, :destroy]
end

View File

@ -124,7 +124,7 @@ class RoutingTest < ActionController::IntegrationTest
should_route :get, "/issues/changes", :controller => 'journals', :action => 'index'
should_route :get, "/issues/bulk_edit", :controller => 'issues', :action => 'bulk_edit'
should_route :post, "/issues/bulk_edit", :controller => 'issues', :action => 'bulk_update'
should_route :post, "/issues/bulk_update", :controller => 'issues', :action => 'bulk_update'
end
context "issue categories" do