* finish task #42848.

This commit is contained in:
王怡栋
2021-09-30 15:49:24 +08:00
parent 5ab6b223ba
commit a14fc4e7f9
+15 -1
View File
@@ -1233,10 +1233,24 @@ class executionModel extends model
$executions = $executionList;
}
$projects = array();
if(empty($projectID))
{
$projects = $this->dao->select('t1.id,t1.name')->from(TABLE_PROJECT)->alias('t1')
->leftJoin(TABLE_EXECUTION)->alias('t2')->on('t1.id=t2.project')
->where('t2.id')->in(array_keys($executions))
->fetchPairs('id', 'name');
}
if($pairs)
{
$executionPairs = array();
foreach($executions as $execution) $executionPairs[$execution->id] = $execution->name;
foreach($executions as $execution)
{
$executionPairs[$execution->id] = '';
if(isset($projects[$execution->project])) $executionPairs[$execution->id] .= $projects[$execution->project] . ' / ';
$executionPairs[$execution->id] .= $execution->name;
}
$executions = $executionPairs;
}