项目里程碑点击列表报500、里程碑编辑删除、项目成员删除编辑不可用

This commit is contained in:
cxt 2017-01-20 17:30:50 +08:00
parent 7d1dbc1656
commit 18b86adcbb
1 changed files with 4 additions and 3 deletions

View File

@ -474,10 +474,11 @@ class ApplicationController < ActionController::Base
render_404 unless @object.present?
@project = @object.project
if @project == nil && !@object.course_id.nil?
if @project == nil && @object.has_attribute?('course_id')
@course = @object.course
else
@contest = @object.contest
if @course.nil? && @object.has_attribute?('contest_id')
@contest = @object.contest
end
end
end