Class: Nuntius::TimebasedEventsJob
- Inherits:
-
ApplicationJob
- Object
- ActiveJob::Base
- ApplicationJob
- Nuntius::TimebasedEventsJob
- Defined in:
- app/jobs/nuntius/timebased_events_job.rb
Instance Method Summary collapse
Instance Method Details
#perform ⇒ Object
5 6 7 8 9 10 11 12 13 |
# File 'app/jobs/nuntius/timebased_events_job.rb', line 5 def perform Nuntius::Template.where.not(interval: nil).each do |template| messenger = Nuntius::BaseMessenger.messenger_for_class(template.klass) messenger.timebased_scope_for(template).each do |object| Nuntius.event(template.event, object) end end end |