2015-03-06 12:31:34 +01:00
|
|
|
<?php
|
|
|
|
use Icinga\Module\Monitoring\Object\Host;
|
|
|
|
|
|
|
|
$i = 0;
|
|
|
|
?>
|
|
|
|
|
2015-02-02 16:26:55 +01:00
|
|
|
<?php if (($hostCount = count($objects)) > 0): ?>
|
2015-03-06 12:31:34 +01:00
|
|
|
<table class="state statesummary">
|
|
|
|
|
|
|
|
<tbody>
|
|
|
|
<?php foreach ($objects as $host): /** @var Host $host */ ?>
|
|
|
|
<?php
|
|
|
|
$i++;
|
|
|
|
if ($i > 5) {
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
|
|
|
|
<tr class="state <?= Host::getStateText($host->host_state); ?><?= $host->host_handled ? ' handled' : '' ?>">
|
|
|
|
<td class="state"><?= Host::getStateText($host->host_state, true); ?><br /></td>
|
2015-04-09 15:44:21 +02:00
|
|
|
<td><?= implode(' ', $this->hostFlags($host)) ?></td>
|
2015-03-06 14:49:33 +01:00
|
|
|
<td class="name oneline"><?= $this->escape($host->getName()); ?></td>
|
|
|
|
<td><?= $this->escape($host->host_output) ?></td>
|
2015-03-06 12:31:34 +01:00
|
|
|
</tr>
|
|
|
|
<?php endforeach ?>
|
2015-04-09 15:44:21 +02:00
|
|
|
</tbody>
|
2015-03-06 12:31:34 +01:00
|
|
|
</table>
|
2015-04-09 15:44:21 +02:00
|
|
|
<div class="hbox-item">
|
|
|
|
<?=
|
|
|
|
$this->qlink(
|
|
|
|
sprintf($this->translate('list all %d hosts ...'), $i),
|
|
|
|
$listAllLink,
|
|
|
|
null,
|
|
|
|
array('data-base-target' => '_next')
|
|
|
|
);
|
|
|
|
?>
|
|
|
|
</div>
|
2015-03-05 18:32:38 +01:00
|
|
|
<?php endif ?>
|
2015-03-06 12:31:34 +01:00
|
|
|
|