parent
371f895188
commit
96c7b22c16
|
@ -1,174 +1,129 @@
|
|||
<div class="controls">
|
||||
<?= $this->render('partials/host/objects-header.phtml') ?>
|
||||
<?= $this->render('partials/host/objects-header.phtml'); ?>
|
||||
</div>
|
||||
<div class="content">
|
||||
<?php if (($hostCount = count($objects)) === 0): ?>
|
||||
<?= $this->translate('No hosts matching the filter') ?>
|
||||
<?= $this->translate('No hosts matching the filter'); ?>
|
||||
<?php else: ?>
|
||||
<h3>
|
||||
<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'%u Host',
|
||||
'%u Hosts',
|
||||
$hostCount
|
||||
),
|
||||
<h3><?= sprintf($this->translatePlural('%u Host', '%u Hosts', $hostCount), $hostCount); ?></h3>
|
||||
<div><?= $this->qlink(
|
||||
sprintf($this->translate('List all %u hosts'), $hostCount),
|
||||
$listAllLink
|
||||
); ?></div>
|
||||
<div>
|
||||
<?= $checkNowForm; ?>
|
||||
</div>
|
||||
<div><?= $this->qlink(
|
||||
$this->icon('reschedule') . ' ' . sprintf(
|
||||
$this->translate('Reschedule the next check for all %u hosts'),
|
||||
$hostCount
|
||||
) ?>
|
||||
</h3>
|
||||
|
||||
<div>
|
||||
<a href="<?= $listAllLink ?>" title="<?= sprintf(
|
||||
$this->translate('List all %u hosts'),
|
||||
),
|
||||
$rescheduleAllLink,
|
||||
null,
|
||||
null,
|
||||
false
|
||||
); ?></div>
|
||||
<div><?= $this->qlink(
|
||||
$this->icon('plug') . ' ' . sprintf($this->translate('Schedule a downtime for all %u hosts'), $hostCount),
|
||||
$downtimeAllLink,
|
||||
null,
|
||||
null,
|
||||
false
|
||||
); ?></div>
|
||||
<div><?= $this->qlink(
|
||||
$this->icon('reply') . ' ' . sprintf(
|
||||
$this->translate('Submit a passive check result for all %u hosts'),
|
||||
$hostCount
|
||||
); ?>">
|
||||
<?= $this->translate('List all') ?>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
),
|
||||
$processCheckResultAllLink,
|
||||
null,
|
||||
null,
|
||||
false
|
||||
); ?></div>
|
||||
<?php if (($unhandledCount = count($unhandledObjects)) > 0): ?>
|
||||
<div>
|
||||
<?= $checkNowForm ?>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<a href="<?= $rescheduleAllLink ?>">
|
||||
<?= $this->icon('reschedule'); ?>
|
||||
<?= $this->translate('Reschedule host checks') ?>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<a href="<?= $downtimeAllLink ?>">
|
||||
<?= $this->icon('plug'); ?>
|
||||
<?= $this->translate('Schedule host downtimes') ?>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<a href="<?= $processCheckResultAllLink; ?>">
|
||||
<?= $this->icon('reply'); ?>
|
||||
<?= $this->translate('Submit passive check results'); ?>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<?php if (! empty($unhandledObjects)): ?>
|
||||
<h3>
|
||||
<?php $unhandledCount = count($unhandledObjects) ?>
|
||||
<?= sprintf(
|
||||
<h3><?= sprintf(
|
||||
$this->translatePlural(
|
||||
'%u Unhandled Host Problem',
|
||||
'%u Unhandled Host Problems',
|
||||
$unhandledCount
|
||||
),
|
||||
$unhandledCount
|
||||
) ?>
|
||||
</h3>
|
||||
<div>
|
||||
<a href="<?= $downtimeUnhandledLink ?>" title="<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'Schedule downtime for %u unhandled host problem',
|
||||
'Schedule downtimes for %u unhandled host problems',
|
||||
$unhandledCount
|
||||
),
|
||||
$unhandledCount
|
||||
) ?>">
|
||||
<?= $this->icon('plug'); ?>
|
||||
<?= sprintf(
|
||||
); ?></h3>
|
||||
<div><?= $this->qlink(
|
||||
$this->icon('plug') . ' ' . sprintf(
|
||||
$this->translatePlural(
|
||||
'Schedule downtime for unhandled host problem',
|
||||
'Schedule downtimes for unhandled host problems',
|
||||
'Schedule a downtime for %u unhandled host problem',
|
||||
'Schedule a downtime for %u unhandled host problems',
|
||||
$unhandledCount
|
||||
),
|
||||
$unhandledCount
|
||||
) ?>
|
||||
</a>
|
||||
</div>
|
||||
<div>
|
||||
<a href="<?= $acknowledgeUnhandledLink ?>" title="<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'Acknowledge %u unhandled host problem',
|
||||
'Acknowledge %u unhandled host problems',
|
||||
$unhandledCount
|
||||
),
|
||||
$unhandledCount
|
||||
) ?>">
|
||||
<?= $this->icon('ok'); ?>
|
||||
<?= sprintf(
|
||||
$downtimeUnhandledLink,
|
||||
null,
|
||||
null,
|
||||
false
|
||||
); ?></div>
|
||||
<div><?= $this->qlink(
|
||||
$this->icon('ok') . ' ' . sprintf(
|
||||
$this->translatePlural(
|
||||
'Acknowledge unhandled host problem',
|
||||
'Acknowledge unhandled host problems',
|
||||
'Acknowledge %u unhandled host problem',
|
||||
'Acknowledge %u unhandled host problems',
|
||||
$unhandledCount
|
||||
),
|
||||
$unhandledCount
|
||||
) ?>
|
||||
</a>
|
||||
),
|
||||
$acknowledgeUnhandledLink,
|
||||
null,
|
||||
null,
|
||||
false
|
||||
); ?></div>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if (! empty($acknowledgedObjects)): ?>
|
||||
<h2>
|
||||
<?php $acknowledgedCount = count($acknowledgedObjects) ?>
|
||||
<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'%u Acknowledged Host Problem',
|
||||
'%u Acknowledged Host Problems',
|
||||
$acknowledgedCount
|
||||
),
|
||||
<?php endif ?>
|
||||
<?php if (($acknowledgedCount = count($acknowledgedObjects)) > 0): ?>
|
||||
<div>
|
||||
<h2><?= sprintf(
|
||||
$this->translatePlural(
|
||||
'%u Acknowledged Host Problem',
|
||||
'%u Acknowledged Host Problems',
|
||||
$acknowledgedCount
|
||||
) ?>
|
||||
</h2>
|
||||
<div>
|
||||
<?= $removeAckForm ?>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if (! empty($objectsInDowntime)): ?>
|
||||
<h2>
|
||||
<?php $inDowntimeCount = count($objectsInDowntime) ?>
|
||||
<a href="<?= $inDowntimeLink ?>"
|
||||
title="<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'List %u host which is in downtime',
|
||||
'List %u hosts which are in downtime',
|
||||
$inDowntimeCount
|
||||
),
|
||||
$inDowntimeCount
|
||||
) ?>">
|
||||
<?= $this->icon('plug'); ?>
|
||||
<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'List %u host currently in downtime',
|
||||
'List %u hosts currently downtime',
|
||||
$inDowntimeCount
|
||||
),
|
||||
$inDowntimeCount
|
||||
) ?>
|
||||
</a>
|
||||
</h2>
|
||||
<?php endif ?>
|
||||
|
||||
<?php $commentCount = count($objects->getComments()) ?>
|
||||
<?php if ($commentCount): ?>
|
||||
<h2>
|
||||
<a href="<?= $commentsLink ?>"
|
||||
title="<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'List %u host comment',
|
||||
'List %u host comments',
|
||||
$commentCount
|
||||
),
|
||||
$commentCount
|
||||
) ?>">
|
||||
<?= $this->icon('comment'); ?>
|
||||
<?= sprintf(
|
||||
$this->translatePlural(
|
||||
'List %u host comment',
|
||||
'List %u host comments',
|
||||
$commentCount
|
||||
),
|
||||
$commentCount
|
||||
) ?>
|
||||
</a>
|
||||
</h2>
|
||||
<?php endif ?>
|
||||
),
|
||||
$acknowledgedCount
|
||||
); ?></h2>
|
||||
<?= $removeAckForm ?>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
<?php if (($inDowntimeCount = count($objectsInDowntime)) > 0): ?>
|
||||
<h2><?= $this->qlink(
|
||||
$this->icon('plug') . ' ' . sprintf(
|
||||
$this->translatePlural(
|
||||
'List %u host currently in downtime',
|
||||
'List %u hosts currently in downtime',
|
||||
$inDowntimeCount
|
||||
),
|
||||
$inDowntimeCount
|
||||
),
|
||||
$inDowntimeLink,
|
||||
null,
|
||||
null,
|
||||
false
|
||||
); ?></h2>
|
||||
<?php endif ?>
|
||||
<?php if (($commentCount = count($objects->getComments())) > 0): ?>
|
||||
<h2><?= $this->qlink(
|
||||
$this->icon('comment') . ' ' . sprintf(
|
||||
$this->translatePlural(
|
||||
'List %u host comment',
|
||||
'List %u host comments',
|
||||
$commentCount
|
||||
),
|
||||
$commentCount
|
||||
),
|
||||
$commentsLink,
|
||||
null,
|
||||
null,
|
||||
false
|
||||
); ?></h2>
|
||||
<?php endif ?>
|
||||
<?php endif ?>
|
||||
</div>
|
||||
</div>
|
Loading…
Reference in New Issue