From 8522140182b7c65d0a3d712d447402a987bf67df Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Fri, 29 May 2015 14:37:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=BD=93=E5=89=8D=E4=BD=9C?= =?UTF-8?q?=E5=93=81=E4=B8=BA=E5=8C=BF=E8=AF=84=E5=88=97=E8=A1=A8=E7=9A=84?= =?UTF-8?q?=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/student_work_controller.rb | 2 ++ app/views/student_work/_student_work.html.erb | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/controllers/student_work_controller.rb b/app/controllers/student_work_controller.rb index 2cef3f40c..a9733c2d4 100644 --- a/app/controllers/student_work_controller.rb +++ b/app/controllers/student_work_controller.rb @@ -12,6 +12,8 @@ class StudentWorkController < ApplicationController @is_teacher = User.current.allowed_to?(:as_teacher,@course) #老师 || 非匿评作业 || 匿评结束 显示所有的作品 @show_all = @is_teacher || @homework.homework_type != 1 || @homework.homework_detail_manual.comment_status == 3 + #当前列表为匿评列表 + @is_evaluation = !@is_teacher && @homework.homework_type == 1 && @homework.homework_detail_manual.comment_status == 2 if @show_all @stundet_works = search_homework_member @homework.student_works.order("#{@order} #{@b_sort}"),@name else #学生 diff --git a/app/views/student_work/_student_work.html.erb b/app/views/student_work/_student_work.html.erb index 568172970..3d288c302 100644 --- a/app/views/student_work/_student_work.html.erb +++ b/app/views/student_work/_student_work.html.erb @@ -1,4 +1,4 @@ - +