From c99af4cb7bf7c152996911d7dc23bce9774fda16 Mon Sep 17 00:00:00 2001 From: alan <547533434@qq.com> Date: Mon, 22 Dec 2014 11:26:21 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E3=80=8A=E4=B8=AA=E4=BA=BA?= =?UTF-8?q?=E4=B8=BB=E9=A1=B5=E5=87=BA=E7=8E=B0=E6=B2=A1=E6=9D=83=E9=99=90?= =?UTF-8?q?=E8=AE=BF=E9=97=AE=E9=93=BE=E6=8E=A5=E3=80=8Bbug=20Signed-off-b?= =?UTF-8?q?y:=20alan=20<547533434@qq.com>?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/users_controller.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index 410818fdb..48a7aa898 100644 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -436,9 +436,7 @@ class UsersController < ApplicationController activity = activity.reject { |e| ((e.act_type=="Issue") && ( !e.act.visible?(User.current))) || ((e.act_type == "Journal") && (!e.act.project.visible?(User.current))) || - ((e.act_type == "Bid") && (e.act.homework_for_courses.count > 0 && - (!e.act.homework_for_courses.first.course.visible?(User.current) || - !User.current.member_of_course?(e.act.homework_for_courses.first.course) || !User.current.admin?))) + ((e.act_type == "Bid") && ((!User.current.member_of_course?(e.act.courses.first) || !User.current.admin?))) } @activity_count = activity.count @activity_pages = Paginator.new @activity_count, pre_count, params['page']