From 09fa1197f6b50c314db6bca01a408c90f430cb06 Mon Sep 17 00:00:00 2001 From: xieqiyu Date: Wed, 6 Apr 2022 16:59:00 +0800 Subject: [PATCH] * Fix bug#20278. --- module/bug/model.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/module/bug/model.php b/module/bug/model.php index 1545d90f87..e2f6587558 100644 --- a/module/bug/model.php +++ b/module/bug/model.php @@ -2665,7 +2665,14 @@ class bugModel extends model $bugs = $this->dao->select('*')->from(TABLE_BUG)->where($bugQuery) ->beginIF(!$this->app->user->admin)->andWhere('execution')->in('0,' . $this->app->user->view->sprints)->fi() ->beginIF($excludeBugs)->andWhere('id')->notIN($excludeBugs)->fi() - ->beginIF($projectID)->andWhere('project')->eq($projectID)->fi() + + ->beginIF($projectID) + ->andWhere('project', true)->eq($projectID) + ->orWhere('project')->eq(0) + ->andWhere('openedBuild')->eq('trunk') + ->markRight(1) + ->fi() + ->andWhere('deleted')->eq(0) ->orderBy($orderBy)->page($pager)->fetchAll(); return $bugs;