Class: Renalware::Reporting::AuditRefreshmentsController

Inherits:
BaseController show all
Defined in:
app/controllers/renalware/reporting/audit_refreshments_controller.rb

Instance Method Summary collapse

Methods inherited from BaseController

#patient

Instance Method Details

#createObject

TODO: Move to Job



12
13
14
15
16
17
# File 'app/controllers/renalware/reporting/audit_refreshments_controller.rb', line 12

def create
  authorize audit
  RefreshAuditDataJob.perform_later(audit)
  flash.now[:notice] = "Data will be refreshed in the background, please check back later"
  render locals: { audit_id: audit.id }
end