You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
541 B
19 lines
541 B
6 years ago
|
#coding=utf-8
|
||
|
# 执行示例 bundle exec rake excellent_course_exercise:student_answer args=149,2903
|
||
|
desc "同步精品课的学生试卷数据"
|
||
|
namespace :excellent_course_exercise do
|
||
|
task :student_answer => :environment do
|
||
|
|
||
|
course = Course.find_by(id: 2933)
|
||
|
exercises = course.exercises
|
||
|
|
||
|
participant_count = 1042
|
||
|
pass_count = 823
|
||
|
|
||
|
members_1 = course.students.order("id asc").limit(987)
|
||
|
members_2 = course.students.order("id asc").limit(1042)
|
||
|
members_1 = course.students.order("id asc").limit(322)
|
||
|
|
||
|
|
||
|
end
|
||
|
end
|