diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-03-01 20:22:08 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-03-01 20:22:08 +0000 |
commit | 7448e0dbc41a53f643ac3c8ebd486d9aa02f593b (patch) | |
tree | ee07026dcfa17c2e13e0723f9dff25150c263d49 /app/controllers/issues_controller.rb | |
parent | ac46497f1abd9e2e69a0b3c4848d8825847d1934 (diff) | |
download | redmine-7448e0dbc41a53f643ac3c8ebd486d9aa02f593b.tar.gz redmine-7448e0dbc41a53f643ac3c8ebd486d9aa02f593b.zip |
Fixed that the bulk edit/copy form does not propose versions and categories for the target project (#10350).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9046 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers/issues_controller.rb')
-rw-r--r-- | app/controllers/issues_controller.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb index 63b3412be..b1a383c66 100644 --- a/app/controllers/issues_controller.rb +++ b/app/controllers/issues_controller.rb @@ -221,7 +221,7 @@ class IssuesController < ApplicationController if User.current.allowed_to?(:move_issues, @projects) @allowed_projects = Issue.allowed_target_projects_on_move if params[:issue] - @target_project = @allowed_projects.detect {|p| p.id.to_s == params[:issue][:project_id]} + @target_project = @allowed_projects.detect {|p| p.id.to_s == params[:issue][:project_id].to_s} if @target_project target_projects = [@target_project] end @@ -233,6 +233,8 @@ class IssuesController < ApplicationController @custom_fields = target_projects.map{|p|p.all_issue_custom_fields}.reduce(:&) @assignables = target_projects.map(&:assignable_users).reduce(:&) @trackers = target_projects.map(&:trackers).reduce(:&) + @versions = target_projects.map {|p| p.shared_versions.open}.reduce(:&) + @categories = target_projects.map {|p| p.issue_categories}.reduce(:&) @safe_attributes = @issues.map(&:safe_attribute_names).reduce(:&) render :layout => false if request.xhr? |