@ -1,6 +1,6 @@
# 学生加入课堂时创建相关任务作品
class CourseAddStudentCreateWorksJob < ApplicationJob
queue_as :course_member
queue_as :default
def perform(course_id, student_ids)
course = Course.find_by(id: course_id)
@ -1,5 +1,5 @@
class CourseDeleteStudentDeleteWorksJob < ApplicationJob
# 毕设任务的交叉评阅分配
class GraduationTaskCrossCommentJob < ApplicationJob
queue_as :evaluation_comment
def perform(graduation_task_id)
task = GraduationTask.find_by(id: graduation_task_id)
class HomeworkAbsencePenaltyCalculationJob < ApplicationJob
queue_as :score
def perform(homework_common_id)
homework_common = HomeworkCommon.find_by(id: homework_common_id)
class HomeworkEndUpdateScoreJob < ApplicationJob
# 不允许补交的作业截止后,或者补交截止后需要重新计算一次作业成绩
def perform(homework_id)
homework = HomeworkCommon.find_by(id: homework_id)
class HomeworkEvaluationCommentAssginJob < ApplicationJob
def get_assigned_homeworks(student_works, n, index)
student_works += student_works
class HomeworkPublishUpdateWorkStatusJob < ApplicationJob
# 作业发布时更新学生(发布前已开启过实训)的作业状态和成绩
def perform(group_ids, homework_id)
# Do something later
@ -3,7 +3,4 @@
:logfile: log/sidekiq.log
:queues:
- [default, 3]
- [score, 4]
- [evaluation_comment, 5]
- [course_member, 6]
- [notify, 100]