Small fixes
This commit is contained in:
parent
4c415aac5c
commit
8086292b1b
|
@ -73,9 +73,9 @@ class Monitoring_ListController extends Controller
|
|||
$stateColumn = 'host_hard_state';
|
||||
$stateChangeColumn = 'host_last_hard_state_change';
|
||||
} else {
|
||||
$stateType = 'soft';
|
||||
$stateColumn = 'host_state';
|
||||
$stateChangeColumn = 'host_last_state_change';
|
||||
$stateType = 'soft';
|
||||
}
|
||||
|
||||
$this->addTitleTab('hosts');
|
||||
|
@ -148,7 +148,7 @@ class Monitoring_ListController extends Controller
|
|||
}
|
||||
}
|
||||
$this->setAutorefreshInterval(10);
|
||||
|
||||
|
||||
$columns = array_merge(array(
|
||||
'host_name',
|
||||
'host_state',
|
||||
|
|
|
@ -10,9 +10,8 @@
|
|||
if (count($groupData) === 0) {
|
||||
echo t('No contacts matching the filter');
|
||||
}
|
||||
?>
|
||||
|
||||
<?php foreach ($groupData as $groupName => $groupInfo): ?>
|
||||
foreach ($groupData as $groupName => $groupInfo): ?>
|
||||
<div class="box contactgroup">
|
||||
<h2><?= $groupInfo['alias']; ?></h2>
|
||||
<?php if ($groupInfo['alias'] !== $groupName): ?>
|
||||
|
@ -31,8 +30,8 @@ if (count($groupData) === 0) {
|
|||
<p>
|
||||
<?php if ($c->contact_email): ?>
|
||||
<?= $c->contact_email; ?>
|
||||
<?php endif ?>
|
||||
<?php if ($c->contact_pager): ?>
|
||||
<?php endif;
|
||||
if ($c->contact_pager): ?>
|
||||
<br />
|
||||
<?= $c->contact_pager; ?>
|
||||
<?php endif ?>
|
||||
|
|
|
@ -10,7 +10,7 @@ $contactHelper = $this->getHelper('ContactFlags');
|
|||
<?= $this->paginationControl($contacts, null, null, array('preserve' => $this->preserve)); ?>
|
||||
</div>
|
||||
|
||||
<div class="content contacts">
|
||||
<div data-base-target="_next" class="content contacts">
|
||||
<?php
|
||||
if (count($contacts) === 0) {
|
||||
echo t('No contacts matching the filter');
|
||||
|
@ -20,14 +20,17 @@ $contactHelper = $this->getHelper('ContactFlags');
|
|||
<div style="background-color: lightgray; padding: 0.5em; border-radius: 0.5em; overflow: hidden; margin: 0.125em; float: left;">
|
||||
<img src="<?= $this->href('/static/gravatar', array('email' => $contact->contact_email )) ?>"
|
||||
style="width: 60px; border: 4px solid white; border-radius: 8px; margin-right: 8px; float: left;" />
|
||||
<strong><?= $contact->contact_name ?></strong> (<?= $contact->contact_alias ?>)
|
||||
<a href="<?= $this->href(
|
||||
'monitoring/show/contact',
|
||||
array('contact' => $contact->contact_name)
|
||||
) ?>"><strong><?= $contact->contact_name ?></strong></a> (<?= $contact->contact_alias ?>)
|
||||
<?php
|
||||
foreach (array(
|
||||
$contact->contact_email => 'eMail: <a href="mailto:%1$s">%1$s</a>',
|
||||
$contact->contact_pager => 'Pager: %s',
|
||||
$contact->contact_notify_service_timeperiod => 'Service notification period: %s',
|
||||
$contact->contact_notify_host_timeperiod => 'Host notification period: %s'
|
||||
) as $value => $format):
|
||||
'eMail: <a href="mailto:%1$s">%1$s</a>' => $contact->contact_email,
|
||||
'Pager: %s' => $contact->contact_pager,
|
||||
'Service notification period: %s' => $contact->contact_notify_service_timeperiod,
|
||||
'Host notification period: %s' => $contact->contact_notify_host_timeperiod
|
||||
) as $format => $value):
|
||||
if ($value): ?>
|
||||
<br />
|
||||
<?php
|
||||
|
|
|
@ -4,9 +4,9 @@ $helper = $this->getHelper('CommandForm');
|
|||
<div class="controls">
|
||||
<?= $this->tabs ?>
|
||||
<div style="margin: 1em">
|
||||
<?= $this->sortControl->render($this); ?>
|
||||
<?= $this->sortControl->render($this); ?>
|
||||
</div>
|
||||
<?= $this->paginationControl($downtimes, null, null, array('preserve' => $this->preserve)); ?>
|
||||
<?= $this->paginationControl($downtimes, null, null, array('preserve' => $this->preserve)); ?>
|
||||
</div>
|
||||
|
||||
<div class="content downtimes">
|
||||
|
@ -16,8 +16,7 @@ $helper = $this->getHelper('CommandForm');
|
|||
if (count($downtimes) === 0) {
|
||||
echo t('No downtimes matching the filter');
|
||||
}
|
||||
?>
|
||||
<?php foreach ($this->downtimes as $downtime): ?>
|
||||
foreach ($this->downtimes as $downtime): ?>
|
||||
<tr>
|
||||
<td>
|
||||
<?= $this->dateFormat()->formatDateTime($downtime->start); ?> -
|
||||
|
|
Loading…
Reference in New Issue