diff --git a/PHPCI/Controller/IndexController.php b/PHPCI/Controller/IndexController.php index c185d2f3..2404a047 100644 --- a/PHPCI/Controller/IndexController.php +++ b/PHPCI/Controller/IndexController.php @@ -33,7 +33,7 @@ class IndexController extends \PHPCI\Controller $projects = $this->_projectStore->getWhere(array(), 50, 0, array(), array('title' => 'ASC')); $summary = $this->_buildStore->getBuildSummary(); - $summaryView = new b8\View('BuildsTable'); + $summaryView = new b8\View('SummaryTable'); $summaryView->builds = $summary['items']; $this->view->builds = $this->getLatestBuildsHtml(); diff --git a/PHPCI/Store/BuildStore.php b/PHPCI/Store/BuildStore.php index 6b26c3c7..fca490f2 100644 --- a/PHPCI/Store/BuildStore.php +++ b/PHPCI/Store/BuildStore.php @@ -31,7 +31,7 @@ class BuildStore extends BuildStoreBase $count = 0; } - $query = 'SELECT b.* FROM build b LEFT JOIN project p on p.id = b.project_id GROUP BY b.project_id ORDER BY p.title ASC, b.id DESC'; + $query = 'SELECT b.* FROM build b LEFT JOIN project p on p.id = b.project_id ORDER BY p.title ASC, b.id DESC'; $stmt = \b8\Database::getConnection('read')->prepare($query); if ($stmt->execute()) { diff --git a/PHPCI/View/Index/index.phtml b/PHPCI/View/Index/index.phtml index 887b46d3..8ffa4b56 100644 --- a/PHPCI/View/Index/index.phtml +++ b/PHPCI/View/Index/index.phtml @@ -44,10 +44,10 @@
ID | +Health | Project | -Commit | -Branch | +Last Success | +Last Failure | Status | |
---|---|---|---|---|---|---|---|---|
= $project['health'] < 0 ? 'Stormy': ($project['health'] < 5? 'Overcast': 'Sunny') ?> | += $projectId ?> | += empty($project['lastsuccess']) ? 'Never' :$project['lastsuccess']->format("d-m-Y H:i:s" ) ?> | += empty($project['lastfailure']) ? 'Never' :$project['lastfailure']->format("d-m-Y H:i:s" ) ?> | += $project['health'] ?> | += $project['count'] ?> | +