解决作业留言和课程留言导致的bug

This commit is contained in:
huang 2015-12-16 10:03:51 +08:00
parent 41bb37d6d4
commit ac8aa9e0a6
1 changed files with 1 additions and 1 deletions

View File

@ -267,7 +267,7 @@ class JournalsForMessage < ActiveRecord::Base
# 课程成员得分(英雄榜) # 课程成员得分(英雄榜)
def act_as_student_score def act_as_student_score
if !self.user.allowed_to?(:as_teacher, self.jour) if !self.user.allowed_to?(:as_teacher, self.jour) && self.jour_type == "Course"
course_member_score(self.jour_id, self.user_id, "JournalForMessage") course_member_score(self.jour_id, self.user_id, "JournalForMessage")
end end
end end