Added tags for Github builds (UI Fixes).

This commit is contained in:
Dmitry Khomutov 2017-04-22 21:48:54 +07:00
commit bf067e4fda
No known key found for this signature in database
GPG key ID: 7EB36C9576F9ECB9
4 changed files with 39 additions and 23 deletions

View file

@ -25,12 +25,12 @@
<th><?php Lang::out('branch'); ?></th>
<td style="text-align: right">
<a target="_blank" href="<?= $build->getBranchLink(); ?>">
<span class="label label-default"><?= $build->getBranch(); ?></span>
<i class="fa fa-code-fork"></i> <?= $build->getBranch(); ?>
</a>
<?php if ($tag = $build->getTag()): ?> /
<a target="_blank" href="<?= $build->getTagLink(); ?>">
<span class='label label-info'><?= $tag; ?></span>
</a>
<?php if ($tag = $build->getTag()): ?>
(<a target="_blank" href="<?= $build->getTagLink(); ?>">
<i class="fa fa-tag"></i> <?= $tag; ?>
</a>)
<?php endif; ?>
</td>
</tr>
@ -40,7 +40,7 @@
<td style="text-align: right">
<?php
$environment = $build->getEnvironment();
echo !empty($environment) ? ('<span class="label label-default">' . $environment . '</span>') : '—' ;
echo !empty($environment) ? ('<i class="fa fa-gear"> ' . $environment) : '—' ;
?>
</td>
</tr>
@ -48,12 +48,14 @@
<tr>
<th><?php Lang::out('merged_branches'); ?></th>
<td style="text-align: right">
<span class="label label-default"><?php print $build->getBranch() ?></span>
<a target="_blank" href="<?= $build->getBranchLink(); ?>">
<i class="fa fa-code-fork"></i> <?= $build->getBranch(); ?>
</a>
+ <?php
$branches = $build->getExtra('branches');
if (!empty($branches)) {
foreach($branches as $branch) {
?><span class="label label-default"><?php print $branch ?></span><?php
?><i class="fa fa-code-fork"></i> <?php print $branch ?><?php
}
} else {
?>&mdash;<?php