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
7 8 9 |
# File 'app/jobs/external_services/api_job.rb', line 7 def action_class "ExternalServices::ApiActions::#{self.class.to_s.demodulize.gsub(/ApiJob/, '')}".constantize end |
#perform(action_id) ⇒ Object
11 12 13 14 15 16 |
# File 'app/jobs/external_services/api_job.rb', line 11 def perform(action_id) action = action_class.find(action_id) return if action.processed? action.execute! end |