Merge branch 'feature/2.4.0/allow_cross-project_subtasks' into 2.4.0-finn-master

pull/41/head
Romano Licker 13 years ago
commit 51caaf6793
  1. 7
      app/models/issue.rb
  2. 4
      public/javascripts/application.js

@ -151,9 +151,6 @@ class Issue < ActiveRecord::Base
issue.fixed_version = nil issue.fixed_version = nil
end end
issue.project = new_project issue.project = new_project
if issue.parent && issue.parent.project_id != issue.project_id
issue.parent_issue_id = nil
end
end end
if new_tracker if new_tracker
issue.tracker = new_tracker issue.tracker = new_tracker
@ -337,9 +334,7 @@ class Issue < ActiveRecord::Base
# Checks parent issue assignment # Checks parent issue assignment
if @parent_issue if @parent_issue
if @parent_issue.project_id != project_id if !new_record?
errors.add :parent_issue_id, :not_same_project
elsif !new_record?
# moving an existing issue # moving an existing issue
if @parent_issue.root_id != root_id if @parent_issue.root_id != root_id
# we can always move to another tree # we can always move to another tree

@ -336,7 +336,9 @@ function observeParentIssueField(url) {
paramName: 'q', paramName: 'q',
updateElement: function(value) { updateElement: function(value) {
document.getElementById('issue_parent_issue_id').value = value.id; document.getElementById('issue_parent_issue_id').value = value.id;
}}); },
parameters: 'scope=all'
});
} }
function observeRelatedIssueField(url) { function observeRelatedIssueField(url) {

Loading…
Cancel
Save