From dae20069e579bd160eb52883b90a18daa2d2cda8 Mon Sep 17 00:00:00 2001 From: SylorHuang Date: Mon, 24 Jun 2019 21:28:37 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AF=95=E5=8D=B7=E7=9A=84=E5=AE=9E=E8=AE=AD?= =?UTF-8?q?=E9=A2=98=E7=9A=84=E8=AF=84=E5=88=86=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../_exercise_questions.json.jbuilder | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/app/views/exercise_questions/_exercise_questions.json.jbuilder b/app/views/exercise_questions/_exercise_questions.json.jbuilder index afba34c9b..7a05c2e11 100644 --- a/app/views/exercise_questions/_exercise_questions.json.jbuilder +++ b/app/views/exercise_questions/_exercise_questions.json.jbuilder @@ -81,18 +81,6 @@ elsif question.question_type == 5 if (exercise_type == 3 || exercise_type == 4) && (shixun_type.present? && shixun_type > 0 ) #教师评阅/试卷截止后,答案公开/试卷未截止,但学生已做了实训题 json.shixun_details do json.array! shixun_challenges do |s| - - # - # exercise_cha_score = nil - # game = Game.user_games(ex_answerer.id,s.challenge_id).first - # if game.present? - # if game.status == 2 && game.final_score >= 0 - # exercise_cha_score = s.question_score #每一关卡的得分 - # end - # end - user_shixun_score = s.exercise_shixun_answers.where(user_id:ex_answerer.id,exercise_question_id:question.id) - json.exercise_cha_socre user_shixun_score.present? ? user_shixun_score.first.score : -1 - games_score = shixun_game_scores(s,ex_answerer,shixun_type,question.id) user_get_score = games_score[:s_score].present? ? games_score[:s_score] : 0.0 json.shixun_challenge_id s.id