]> source.dussan.org Git - redmine.git/commitdiff
Merged r12910 and r12911 (#16091).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 23 Feb 2014 08:11:59 +0000 (08:11 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 23 Feb 2014 08:11:59 +0000 (08:11 +0000)
git-svn-id: http://svn.redmine.org/redmine/branches/2.5-stable@12920 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/controllers/issues_controller.rb
app/models/issue_query.rb

index 0b6f250199a67da8c5d40f05a3597525f109d369..dbc55cbd4003f080eebc4489e7c2e61bddf135da 100644 (file)
@@ -62,6 +62,9 @@ class IssuesController < ApplicationController
       case params[:format]
       when 'csv', 'pdf'
         @limit = Setting.issues_export_limit.to_i
+        if params[:columns] == 'all'
+          @query.column_names = @query.available_inline_columns.map(&:name)
+        end
       when 'atom'
         @limit = Setting.feeds_limit.to_i
       when 'xml', 'json'
index 9a6d278fe154219308ec861f03ad1e26a8306a9b..bf90f56d1f9e2c242b888bc75327c7822a35eb4d 100644 (file)
@@ -334,6 +334,9 @@ class IssueQuery < Query
       offset(options[:offset])
 
     scope = scope.preload(:custom_values)
+    if has_column?(:author)
+      scope = scope.preload(:author)
+    end
 
     issues = scope.all