phpci/PHPCI/View/Home/index.phtml

65 lines
1.6 KiB
PHTML
Raw Normal View History

2013-05-10 13:28:43 +02:00
<div id="title">
<h1 style="display: inline-block">Dashboard</h1>
</div>
2013-05-03 17:02:53 +02:00
<div class="row">
<div class="col-lg-3">
<ul class="nav nav-pills nav-stacked">
<li class="active"><a href="<?= PHPCI_URL ?>"><i class="icon-home"></i> Dashboard</a></li>
</ul>
2013-05-10 13:28:43 +02:00
<?php if (count($projects)): ?>
<h5>Projects</h5>
<ul class="nav nav-pills nav-stacked">
2013-10-10 02:01:06 +02:00
<?php foreach($projects as $project): ?>
<li><a href="<?= PHPCI_URL ?>project/view/<?php print $project->getId(); ?>"><?php print htmlspecialchars($project->getTitle()); ?></a></li>
2013-05-03 17:02:53 +02:00
<?php endforeach; ?>
</ul>
<?php endif; ?>
</div>
<div class="col-lg-9">
<div class="box">
<h3 class="title">Project Overview</h3>
<table class="table table-striped table-bordered">
<thead>
<tr>
2013-06-05 07:23:47 +02:00
<th>Health</th>
<th>Project</th>
2013-06-05 07:23:47 +02:00
<th>Last Success</th>
<th>Last Failure</th>
2013-06-05 07:49:49 +02:00
<th>Success/Failures</th>
<th style="width: 100px"></th>
</tr>
</thead>
<tbody id="project-overview">
<?php print $summary; ?>
</tbody>
</table>
</div>
<div class="box">
<h3 class="title">Last 5 Builds</h3>
2013-05-10 13:28:43 +02:00
<table class="table table-striped table-bordered">
<thead>
2013-05-03 17:02:53 +02:00
<tr>
2013-05-10 13:28:43 +02:00
<th>ID</th>
2013-05-03 17:02:53 +02:00
<th>Project</th>
<th>Commit</th>
<th>Branch</th>
<th>Status</th>
<th style="width: 90px"></th>
2013-05-03 17:02:53 +02:00
</tr>
2013-05-10 13:28:43 +02:00
</thead>
<tbody id="latest-builds">
<?php print $builds; ?>
2013-05-10 13:28:43 +02:00
</tbody>
2013-05-03 17:02:53 +02:00
</table>
</div>
2013-05-03 17:02:53 +02:00
</div>
2013-05-10 13:28:43 +02:00
</div>
<script>
setInterval(function()
{
$('#latest-builds').load('<?= PHPCI_URL ?>home/latest');
2013-05-10 13:28:43 +02:00
}, 10000);
</script>