dev_course
cxt 6 years ago
parent e071aeb556
commit 2d6ed002d5

@ -31,7 +31,7 @@ class ExercisePublishNotifyJob < ApplicationJob
Tiding.bulk_insert(*attrs) do |worker|
teacher_ids = teachers.pluck(:user_id)
unless exercise.tidings.exists?(parent_container_type: 'ExercisePublish', user_id: teacher_ids)
teacher_ids.find_each do |user_id|
teacher_ids.each do |user_id|
worker.add same_attrs.merge(user_id: user_id)
end
end

@ -2,7 +2,7 @@ class HomeworkEndUpdateScoreJob < ApplicationJob
# 不允许补交的作业截止后,或者补交截止后需要重新计算一次作业成绩
queue_as :score
def perform(*args)
def perform(homework_id)
homework = HomeworkCommon.find_by(id: homework_id)
return if homework.blank?
course = homework.course

Loading…
Cancel
Save