From 3d1242b2f6b8fa01fb18269279d4bb9e888a5fa0 Mon Sep 17 00:00:00 2001 From: daiao <358551898@qq.com> Date: Wed, 25 Dec 2019 15:31:05 +0800 Subject: [PATCH] =?UTF-8?q?hack=E5=A5=96=E5=8A=B1=E9=87=91=E5=B8=81?= =?UTF-8?q?=E7=9A=84=E6=B6=88=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/decorators/grade_decorator.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/decorators/grade_decorator.rb b/app/decorators/grade_decorator.rb index ffffa11c9..b89cd99ce 100644 --- a/app/decorators/grade_decorator.rb +++ b/app/decorators/grade_decorator.rb @@ -31,6 +31,9 @@ module GradeDecorator when 'check_ta_answer' then game = Game.find_by(id: container_id) game.present? ? "查看实训“#{game.challenge.shixun.name}”第#{game.challenge.position}关的TA人解答消耗的金币" : '' + when 'hack' then + hack = Hack.find_by(id: container_id) + game.present? ? "完成了题目解答“#{hack.name}”,获得金币奖励:#{hack.score}" : '' end end end \ No newline at end of file