Merge branch 'develop' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_jupyter

chromesetting
杨树明 5 years ago
commit 1afdaa437d

@ -163,9 +163,12 @@ module ExportHelper
count_2 = common_homeworks.size count_2 = common_homeworks.size
count_3 = group_homeworks.size count_3 = group_homeworks.size
count_4 = tasks.size count_4 = tasks.size
all_user_ids = all_members.pluck(:user_id)
#实训作业 #实训作业
shixun_homeworks.each_with_index do |s,index| shixun_homeworks.each_with_index do |s,index|
all_student_works = s.score_student_works #该实训题的全部用户回答 all_student_works = s.score_student_works.select{|work| all_user_ids.include?(work.user_id)} #该实训题的全部用户回答
title_no = index.to_i + 1 title_no = index.to_i + 1
student_work_to_xlsx(all_student_works,s) student_work_to_xlsx(all_student_works,s)
shixun_work_display_name = format_sheet_name (title_no.to_s + "." + s.name).strip.first(30) shixun_work_display_name = format_sheet_name (title_no.to_s + "." + s.name).strip.first(30)
@ -175,7 +178,7 @@ module ExportHelper
#普通作业 #普通作业
common_homeworks.each_with_index do |c,index| common_homeworks.each_with_index do |c,index|
all_student_works = c.score_student_works #当前用户的对该作业的回答 all_student_works = c.score_student_works.select{|work| all_user_ids.include?(work.user_id)} #当前用户的对该作业的回答
title_no = count_1 + index.to_i + 1 title_no = count_1 + index.to_i + 1
student_work_to_xlsx(all_student_works,c) student_work_to_xlsx(all_student_works,c)
@ -187,7 +190,7 @@ module ExportHelper
#分组作业 #分组作业
group_homeworks.each_with_index do |c,index| group_homeworks.each_with_index do |c,index|
all_student_works = c.score_student_works #当前用户的对该作业的回答 all_student_works = c.score_student_works.select{|work| all_user_ids.include?(work.user_id)} #当前用户的对该作业的回答
title_no = count_1 + count_2 + index.to_i + 1 title_no = count_1 + count_2 + index.to_i + 1
student_work_to_xlsx(all_student_works,c) student_work_to_xlsx(all_student_works,c)
work_name = format_sheet_name (title_no.to_s + "." + c.name).strip.first(30) work_name = format_sheet_name (title_no.to_s + "." + c.name).strip.first(30)
@ -197,7 +200,7 @@ module ExportHelper
#毕设任务 #毕设任务
tasks.each_with_index do |c,index| tasks.each_with_index do |c,index|
all_student_works = c.score_graduation_works #当前用户的对该作业的回答 all_student_works = c.score_graduation_works.select{|work| all_user_ids.include?(work.user_id)} #当前用户的对该作业的回答
title_no = count_1 + count_2 + count_3 + index.to_i + 1 title_no = count_1 + count_2 + count_3 + index.to_i + 1
graduation_work_to_xlsx(all_student_works,c,current_user) graduation_work_to_xlsx(all_student_works,c,current_user)
work_name = format_sheet_name (title_no.to_s + "." + c.name).strip.first(30) work_name = format_sheet_name (title_no.to_s + "." + c.name).strip.first(30)
@ -207,7 +210,7 @@ module ExportHelper
#试卷的导出 #试卷的导出
exercises.each_with_index do |c,index| exercises.each_with_index do |c,index|
all_student_works = c.score_exercise_users #当前用户的对该作业的回答 all_student_works = c.score_exercise_users.select{|work| all_user_ids.include?(work.user_id)} #当前用户的对该作业的回答
title_no = count_1 + count_2 + count_3 + count_4 + index.to_i + 1 title_no = count_1 + count_2 + count_3 + count_4 + index.to_i + 1
get_export_users(c,course,all_student_works) get_export_users(c,course,all_student_works)
work_name = format_sheet_name (title_no.to_s + "." + c.exercise_name).strip.first(30) work_name = format_sheet_name (title_no.to_s + "." + c.exercise_name).strip.first(30)

@ -38,9 +38,9 @@ class VNCContainer extends Component {
} }
shouldComponentUpdate () { // shouldComponentUpdate () {
return false; // return false;
} // }
getSecondDrawerWidth = () => { getSecondDrawerWidth = () => {
return $('#game_right_contents').width() - firstDrawerWidth return $('#game_right_contents').width() - firstDrawerWidth
@ -337,11 +337,11 @@ class VNCContainer extends Component {
width={firstDrawerWidth} width={firstDrawerWidth}
closable={false} closable={false}
onClose={this.onBottomDrawerClose} onClose={this.onBottomDrawerClose}
visible={this.state.bottomDrawer} visible={this.state.bottomDrawer===undefined?false:this.state.bottomDrawer}
className={'codeEvaluateDrawer'} className={'codeEvaluateDrawer'}
placement="bottom" placement="bottom"
getContainer={false} getContainer={false}
style={{ position: 'absolute', bottom: '25px', zIndex: 1 }} style={{ position: 'absolute', bottom: '-25px', zIndex: 1 }}
afterVisibleChange={(visible) => { afterVisibleChange={(visible) => {
if (visible) { if (visible) {
const canvas = $('.vncDisply canvas')[0] const canvas = $('.vncDisply canvas')[0]

Loading…
Cancel
Save