助教也可在个人首页关闭课程
This commit is contained in:
parent
a5d7c50fe3
commit
5d5159f4c7
|
@ -1,6 +1,6 @@
|
|||
<%
|
||||
id = "finish_course_#{course.id}"
|
||||
display = (course.teacher.id == User.current.id || User.current.admin?)
|
||||
display = (User.current.allowed_to?(:as_teacher,course) || User.current.admin?)
|
||||
%>
|
||||
|
||||
<% if display #如果课程已结束%>
|
||||
|
|
Loading…
Reference in New Issue