Class: Crm::Reports::ItemMovedToScrapReportController
- Inherits:
-
CrmController
- Object
- CrmController
- Crm::Reports::ItemMovedToScrapReportController
- Includes:
- Controllers::ReportCommandFlashable
- Defined in:
- app/controllers/crm/reports/item_moved_to_scrap_report_controller.rb
Instance Method Summary collapse
Instance Method Details
#show ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 |
# File 'app/controllers/crm/reports/item_moved_to_scrap_report_controller.rb', line 4 def show @report_command = ::Report::ItemMovedToScrap::ItemMovedToScrapReportCommand.new(item_moved_to_scrap_report_command_params) @result = @report_command.execute flash_report_command_errors respond_to do |format| format.html format.turbo_stream format.csv { send_data @report_command.to_csv, filename: "item-moved-to-scrap-#{Date.current}.csv" } end end |