diff --git a/module/report/model.php b/module/report/model.php index 111f3301d1..c6680be397 100644 --- a/module/report/model.php +++ b/module/report/model.php @@ -99,7 +99,7 @@ class reportModel extends model public function getExecutions($begin = 0, $end = 0) { $permission = common::hasPriv('report', 'showProject') or $this->app->user->admin; - $tasks = $this->dao->select('t1.*, t2.name as executionName, t3.name as projectName')->from(TABLE_TASK)->alias('t1') + $tasks = $this->dao->select('t1.*, IF(t3.multiple = "1", t2.name, "") as executionName, t3.name as projectName')->from(TABLE_TASK)->alias('t1') ->leftJoin(TABLE_EXECUTION)->alias('t2')->on('t1.execution = t2.id') ->leftJoin(TABLE_PROJECT)->alias('t3')->on('t1.project = t3.id') ->where('t1.status')->ne('cancel') @@ -124,6 +124,7 @@ class reportModel extends model $executions[$executionID]->consumed = 0; } + $executions[$executionID]->projectID = $task->project; $executions[$executionID]->projectName = $task->projectName; $executions[$executionID]->name = $task->executionName; $executions[$executionID]->estimate += $task->estimate; diff --git a/module/report/view/projectdeviation.html.php b/module/report/view/projectdeviation.html.php index 09a741c41b..764a974cb8 100644 --- a/module/report/view/projectdeviation.html.php +++ b/module/report/view/projectdeviation.html.php @@ -58,11 +58,15 @@
- $execution):?> + $execution):?>