* [bug#63939,done,0.5h,0h] Fix show delayed executions error.

This commit is contained in:
wangyuting
2025-07-11 09:46:38 +08:00
committed by wangzemei
parent fc7d4c86fc
commit 326c5eff3f
+4 -2
View File
@@ -1246,8 +1246,9 @@ class executionModel extends model
->beginIF($type == 'all')->andWhere('t2.type')->in('sprint,stage,kanban')->fi()
->beginIF($type != 'all')->andWhere('t2.type')->eq($type)->fi()
->beginIF($status == 'undone')->andWhere('t2.status')->notIN('done,closed')->fi()
->beginIF($status == 'delayed')->andWhere('t2.end')->gt('1970-1-1')->andWhere('t2.end')->lt(date(DT_DATE1))->andWhere('t2.status')->notin('done,closed,suspended')->fi()
->beginIF($branch)->andWhere('t1.branch')->eq($branch)->fi()
->beginIF($status != 'all' and $status != 'undone')->andWhere('status')->in($status)->fi()
->beginIF($status != 'all' && $status != 'undone' && $status != 'delayed')->andWhere('t2.status')->in($status)->fi()
->beginIF(!$this->app->user->admin and isset($this->app->user->view))->andWhere('t2.id')->in($this->app->user->view->sprints)->fi()
->beginIF(!$withChildren)->andWhere('grade')->eq(1)->fi()
->orderBy('order_desc')
@@ -1263,7 +1264,8 @@ class executionModel extends model
->beginIF($type == 'all')->andWhere('type')->in('sprint,stage,kanban')->fi()
->beginIF($type != 'all')->andWhere('type')->eq($type)->fi()
->beginIF($status == 'undone')->andWhere('status')->notIN('done,closed')->fi()
->beginIF($status != 'all' and $status != 'undone')->andWhere('status')->in($status)->fi()
->beginIF($status == 'delayed')->andWhere('end')->gt('1970-1-1')->andWhere('end')->lt(date(DT_DATE1))->andWhere('status')->notin('done,closed,suspended')->fi()
->beginIF($status != 'all' && $status != 'undone' && $status != 'delayed')->andWhere('status')->in($status)->fi()
->beginIF($projectID)->andWhere('project')->eq($projectID)->fi()
->beginIF(!$this->app->user->admin and isset($this->app->user->view))->andWhere('id')->in($this->app->user->view->sprints)->fi()
->beginIF(!$withChildren)->andWhere('grade')->eq(1)->fi()