Class: Tasks::Contents::FilterController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- Tasks::Contents::FilterController
- Includes:
- TaskControllerConfiguration
- Defined in:
- app/controllers/tasks/contents/filter_controller.rb
Instance Method Summary collapse
Methods included from TaskControllerConfiguration
Instance Method Details
#download ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 |
# File 'app/controllers/tasks/contents/filter_controller.rb', line 4 def download @contents = ::Queries::Content::Filter.new(params).all .order('contents.otu_id, contents.topic_id') send_data( Export::CSV.generate_csv( @contents, exclude_columns: %w{updated_by_id created_by_id project_id} ), type: 'text', filename: "contents_#{DateTime.now}.tsv" ) end |