|
|
|
@ -541,7 +541,7 @@ class StudentWorksController < ApplicationController
|
|
|
|
|
def destroy_score
|
|
|
|
|
score = @work.student_works_scores.find_by(id: params[:score_id])
|
|
|
|
|
tip_exception("该评阅记录不存在") unless score.present?
|
|
|
|
|
tip_exception("该评阅记录不能删除") unless score.allow_delete(@current_user, @user_course_identity)
|
|
|
|
|
tip_exception("该评阅记录不能删除") unless score.allow_delete(current_user, @user_course_identity)
|
|
|
|
|
begin
|
|
|
|
|
score.destroy
|
|
|
|
|
normal_status(0,"删除成功")
|
|
|
|
|