+ Add consumed and teamCount of projects for performance optimization.

This commit is contained in:
zhujinyong
2023-05-12 09:31:20 +08:00
parent 94b818161c
commit d5560c2d35
7 changed files with 28 additions and 80 deletions
-1
View File
@@ -3060,7 +3060,6 @@ class bugModel extends model
$bugs = $this->dao->select("*, IF(`pri` = 0, {$this->config->maxPriValue}, `pri`) as priOrder, IF(`severity` = 0, {$this->config->maxPriValue}, `severity`) as severityOrder")->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', true)->eq($projectID)
->orWhere('project')->eq(0)