非项目成员URL访问私有项目500问题
This commit is contained in:
parent
64da95e900
commit
7f0da03fea
|
@ -457,7 +457,6 @@ class ProjectsController < ApplicationController
|
|||
end
|
||||
end
|
||||
@members = paginateHelper @members
|
||||
render :layout => 'base_courses' if @project.project_type == 1
|
||||
end
|
||||
|
||||
#判断指定用户是否为课程教师
|
||||
|
@ -676,9 +675,9 @@ class ProjectsController < ApplicationController
|
|||
|
||||
def memberAccess
|
||||
# 是课程,则判断当前用户是否参加了课程
|
||||
return 0 if @project.project_type == Project::ProjectType_project
|
||||
currentUser = User.current
|
||||
render_403 unless currentUser.member_of?(@project)
|
||||
# return 0 if @project.project_type == Project::ProjectType_project
|
||||
# currentUser = User.current
|
||||
render_403 unless User.current.member_of?(@project)
|
||||
end
|
||||
|
||||
def toggleCourse
|
||||
|
|
Loading…
Reference in New Issue