summaryrefslogtreecommitdiffstats
path: root/app/controllers
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2009-11-04 13:22:26 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2009-11-04 13:22:26 +0000
commit27e3fa2bed6bd9ca543d22053c3f1c1eab01e051 (patch)
tree01b75e9cef292045ef80a094ce434a55af33c808 /app/controllers
parent4ea714fb911ba78918688fc5236cc670d209c55c (diff)
downloadredmine-27e3fa2bed6bd9ca543d22053c3f1c1eab01e051.tar.gz
redmine-27e3fa2bed6bd9ca543d22053c3f1c1eab01e051.zip
Use FasterCSV or ruby1.9 CSV instead of ruby1.8 builtin CSV.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3007 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/issues_controller.rb2
-rw-r--r--app/controllers/timelog_controller.rb4
2 files changed, 3 insertions, 3 deletions
diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb
index 332734d16..f484ed82e 100644
--- a/app/controllers/issues_controller.rb
+++ b/app/controllers/issues_controller.rb
@@ -82,7 +82,7 @@ class IssuesController < ApplicationController
render :template => 'issues/index.rhtml', :layout => !request.xhr?
}
format.atom { render_feed(@issues, :title => "#{@project || Setting.app_title}: #{l(:label_issue_plural)}") }
- format.csv { send_data(issues_to_csv(@issues, @project).read, :type => 'text/csv; header=present', :filename => 'export.csv') }
+ format.csv { send_data(issues_to_csv(@issues, @project), :type => 'text/csv; header=present', :filename => 'export.csv') }
format.pdf { send_data(issues_to_pdf(@issues, @project, @query), :type => 'application/pdf', :filename => 'export.pdf') }
end
else
diff --git a/app/controllers/timelog_controller.rb b/app/controllers/timelog_controller.rb
index f53ea72fa..90abb1ebf 100644
--- a/app/controllers/timelog_controller.rb
+++ b/app/controllers/timelog_controller.rb
@@ -147,7 +147,7 @@ class TimelogController < ApplicationController
respond_to do |format|
format.html { render :layout => !request.xhr? }
- format.csv { send_data(report_to_csv(@criterias, @periods, @hours).read, :type => 'text/csv; header=present', :filename => 'timelog.csv') }
+ format.csv { send_data(report_to_csv(@criterias, @periods, @hours), :type => 'text/csv; header=present', :filename => 'timelog.csv') }
end
end
@@ -202,7 +202,7 @@ class TimelogController < ApplicationController
:include => [:project, :activity, :user, {:issue => [:tracker, :assigned_to, :priority]}],
:conditions => cond.conditions,
:order => sort_clause)
- send_data(entries_to_csv(@entries).read, :type => 'text/csv; header=present', :filename => 'timelog.csv')
+ send_data(entries_to_csv(@entries), :type => 'text/csv; header=present', :filename => 'timelog.csv')
}
end
end