|
|
|
@ -802,7 +802,6 @@ class StudentWorkController < ApplicationController
|
|
|
|
|
#添加评分,已评分则为修改评分
|
|
|
|
|
def add_score
|
|
|
|
|
@is_last = params[:is_last] == "true"
|
|
|
|
|
render_403 and return if User.current == @work.user #不可以匿评自己的作品
|
|
|
|
|
@is_teacher = User.current.allowed_to?(:as_teacher,@course) || User.current.admin?
|
|
|
|
|
#老师、教辅可以随时评分,学生只能在匿评作业的匿评阶段进行评分
|
|
|
|
|
render_403 and return unless @is_teacher || @homework.homework_detail_manual.comment_status == 2
|
|
|
|
|