From 30e1513b2343f544a2ed60a735ea9f2cd140008c Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sun, 10 May 2015 07:29:40 +0000 Subject: [PATCH] Merged r14239 and r14240 (#19706). git-svn-id: http://svn.redmine.org/redmine/branches/2.6-stable@14254 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/controllers/issues_controller.rb | 2 +- app/helpers/issues_helper.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb index f1fed83b8..99e14829b 100644 --- a/app/controllers/issues_controller.rb +++ b/app/controllers/issues_controller.rb @@ -112,7 +112,7 @@ class IssuesController < ApplicationController @journals.reject! {|journal| !journal.notes? && journal.visible_details.empty?} @journals.reverse! if User.current.wants_comments_in_reverse_order? - @changesets = @issue.changesets.visible.all + @changesets = @issue.changesets.visible.preload(:repository, :user).to_a @changesets.reverse! if User.current.wants_comments_in_reverse_order? @relations = @issue.relations.select {|r| r.other_issue(@issue) && r.other_issue(@issue).visible? } diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb index f3a876c4d..ab78fe062 100644 --- a/app/helpers/issues_helper.rb +++ b/app/helpers/issues_helper.rb @@ -79,7 +79,7 @@ module IssuesHelper def render_descendants_tree(issue) s = '
' - issue_list(issue.descendants.visible.sort_by(&:lft)) do |child, level| + issue_list(issue.descendants.visible.preload(:status, :priority, :tracker).sort_by(&:lft)) do |child, level| css = "issue issue-#{child.id} hascontextmenu" css << " idnt idnt-#{level}" if level > 0 s << content_tag('tr', -- 2.39.5