Allow mass status update through context menu. #3411

NB: it cannot be done with issues from different projects, same as
other fields. This will be addressed separately, see #5332.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4055 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Baptiste Barth
2010-09-03 19:54:24 +00:00
parent c1068bf0cd
commit a2ce6e236c
3 changed files with 22 additions and 10 deletions
@@ -6,6 +6,12 @@ class ContextMenusController < ApplicationController
if (@issues.size == 1)
@issue = @issues.first
@allowed_statuses = @issue.new_statuses_allowed_to(User.current)
else
@allowed_statuses = @issues.map do |i|
i.new_statuses_allowed_to(User.current)
end.inject do |memo,s|
memo & s
end
end
projects = @issues.collect(&:project).compact.uniq
@project = projects.first if projects.size == 1