Class: ExternalServices::ApiJob
- Inherits:
-
ActiveJob::Base
- Object
- ActiveJob::Base
- ExternalServices::ApiJob
- Defined in:
- app/jobs/external_services/api_job.rb
Instance Method Summary collapse
Instance Method Details
#action_class ⇒ Object
5 6 7 |
# File 'app/jobs/external_services/api_job.rb', line 5 def action_class "ExternalServices::ApiActions::#{self.class.to_s.demodulize.gsub(/ApiJob/, '')}".constantize end |
#perform(action_id) ⇒ Object
9 10 11 12 13 14 |
# File 'app/jobs/external_services/api_job.rb', line 9 def perform(action_id) action = action_class.find(action_id) return if action.processed? action.execute! end |