We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 495f154 + 87977d3 commit 8db199cCopy full SHA for 8db199c
1 file changed
app/jobs/enqueue_automated_careplus_reports_job.rb
@@ -1,13 +1,10 @@
1
# frozen_string_literal: true
2
3
-class EnqueueAutomatedCareplusReportsJob
4
- include Sidekiq::Job
5
-
6
- sidekiq_options queue: :careplus
+class EnqueueAutomatedCareplusReportsJob < ApplicationJob
+ queue_as :careplus
7
8
def perform
9
- Team.eligible_for_automated_careplus_reports.ids.each do |team_id|
10
- SendAutomatedCareplusReportsJob.perform_async(team_id)
11
- end
+ ids = Team.eligible_for_automated_careplus_reports.ids
+ SendAutomatedCareplusReportsJob.perform_bulk(ids.zip)
12
end
13
0 commit comments