-
-
Save JoshvaR88/673a361597d26ce990e8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class SalesReportWorker < ApplicationController | |
include Sidekiq::Worker | |
sidekiq_options backtrace: true, retry: false | |
self.view_paths = "app/views" # Where to look for view templates | |
def perform(request_ident, params) | |
@_response = ActionDispatch::Response.new # Needed to avoid "ActionController::RackDelegation#content_type | |
# delegated to @_response.content_type, but @_response is nil" error | |
... | |
html = render template: 'sales_reports/show.js.erb' | |
... | |
end | |
... | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment