From: Jean-Philippe Lang Date: Sat, 18 Jun 2016 06:51:59 +0000 (+0000) Subject: Preload issue status when displaying activity. X-Git-Tag: 3.4.0~888 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=93afc01e06abadd1330851d2ddf1122640144d2c;p=redmine.git Preload issue status when displaying activity. git-svn-id: http://svn.redmine.org/redmine/trunk@15545 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/models/issue.rb b/app/models/issue.rb index 98e348d6a..9cf29532a 100644 --- a/app/models/issue.rb +++ b/app/models/issue.rb @@ -54,7 +54,7 @@ class Issue < ActiveRecord::Base :url => Proc.new {|o| {:controller => 'issues', :action => 'show', :id => o.id}}, :type => Proc.new {|o| 'issue' + (o.closed? ? ' closed' : '') } - acts_as_activity_provider :scope => preload(:project, :author, :tracker), + acts_as_activity_provider :scope => preload(:project, :author, :tracker, :status), :author_key => :author_id DONE_RATIO_OPTIONS = %w(issue_field issue_status)