|
|
|
@ -83,9 +83,9 @@ class Admins::ShixunSettingsController < Admins::BaseController
|
|
|
|
|
sheet1[count_row, 6] = shixun.myshixuns_count
|
|
|
|
|
sheet1[count_row, 7] = shixun.myshixuns.select{|m| m.status == 1}.size
|
|
|
|
|
sheet1[count_row, 8] = shixun.shixun_status
|
|
|
|
|
sheet1[count_row, 9] = shixun.user.show_real_name
|
|
|
|
|
sheet1[count_row, 10] = shixun.user.school_name
|
|
|
|
|
sheet1[count_row, 11] = shixun.user.identity
|
|
|
|
|
sheet1[count_row, 9] = shixun.user&.show_real_name
|
|
|
|
|
sheet1[count_row, 10] = shixun.user&.school_name
|
|
|
|
|
sheet1[count_row, 11] = shixun.user&.identity
|
|
|
|
|
shixun.challenges.each do |challenge|
|
|
|
|
|
sheet1[count_row, 12] = "第#{challenge.position}关"
|
|
|
|
|
sheet1[count_row, 13] = challenge.subject
|
|
|
|
@ -112,13 +112,16 @@ class Admins::ShixunSettingsController < Admins::BaseController
|
|
|
|
|
sheet1[count_row, 2] = shixun.mirror_repositories.select{|mr| mr.main_type == "1"}.first&.type_name
|
|
|
|
|
sheet1[count_row, 3] = shixun.fork_from
|
|
|
|
|
sheet1[count_row, 4] = shixun.shixun_status
|
|
|
|
|
sheet1[count_row, 5] = shixun.user.show_real_name
|
|
|
|
|
sheet1[count_row, 6] = shixun.user.school_name
|
|
|
|
|
sheet1[count_row, 7] = shixun.user.identity
|
|
|
|
|
shixun.challenges.each do |challenge|
|
|
|
|
|
sheet1[count_row, 5] = shixun.user&.show_real_name
|
|
|
|
|
sheet1[count_row, 6] = shixun.user&.school_name
|
|
|
|
|
sheet1[count_row, 7] = shixun.user&.identity
|
|
|
|
|
challenge_count = shixun.challenges.count
|
|
|
|
|
shixun.challenges.each_with_index do |challenge, index|
|
|
|
|
|
sheet1[count_row, 8] = "第#{challenge.position}关"
|
|
|
|
|
sheet1[count_row, 9] = challenge.subject
|
|
|
|
|
count_row += 1
|
|
|
|
|
if index + 1 != challenge_count
|
|
|
|
|
count_row += 1
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
count_row += 1
|
|
|
|
|
end
|
|
|
|
|