monitoring/list: Update content markup in contacts

This commit is contained in:
Eric Lippmann 2016-03-31 09:24:31 +02:00
parent a2d067ba97
commit 1da35eaad4

View File

@ -1,6 +1,6 @@
<?php if (! $this->compact): ?> <?php if (! $this->compact): ?>
<div class="controls"> <div class="controls">
<?= $tabs ?> <?= $this->tabs ?>
<?= $this->paginator ?> <?= $this->paginator ?>
<div class="sort-controls-container"> <div class="sort-controls-container">
<?= $this->limiter ?> <?= $this->limiter ?>
@ -10,8 +10,11 @@
</div> </div>
<?php endif ?> <?php endif ?>
<div class="content"> <div class="content">
<?php if ($contacts->hasResult()): ?> <?php if (! $contacts->hasResult()): ?>
<table class="action table-row-selectable common-table" data-base-target="_next"> <p><?= $this->translate('No contacts found matching the filter') ?></p>
</div>
<?php return; endif ?>
<table class="common-table table-row-selectable" data-base-target="_next">
<thead> <thead>
<tr> <tr>
<th><?= $this->translate('Name') ?></th> <th><?= $this->translate('Name') ?></th>
@ -27,53 +30,54 @@
$contact->contact_name, $contact->contact_name,
'monitoring/show/contact', 'monitoring/show/contact',
array('contact_name' => $contact->contact_name), array('contact_name' => $contact->contact_name),
array('title' => sprintf( array(
'title' => sprintf(
$this->translate('Show detailed information about %s'), $this->translate('Show detailed information about %s'),
$contact->contact_alias $contact->contact_alias
), 'class' => 'rowaction') )
); ?> )
) ?>
</td> </td>
<td> <td>
<?= $this->translate('Email') ?>: <?= $this->translate('Email') ?>:
<a href="mailto:<?= $contact->contact_email; ?>" <a href="mailto:<?= $contact->contact_email ?>"
title="<?= sprintf($this->translate('Send a mail to %s'), $contact->contact_alias); ?>" title="<?= sprintf($this->translate('Send a mail to %s'), $contact->contact_alias) ?>"
aria-label="<?= sprintf($this->translate('Send a mail to %s'), $contact->contact_alias); ?>"> aria-label="<?= sprintf($this->translate('Send a mail to %s'), $contact->contact_alias) ?>">
<?= $this->escape($contact->contact_email); ?> <?= $this->escape($contact->contact_email) ?>
</a> </a>
</td> </td>
<td> <td>
<?php if ($contact->contact_pager): ?> <?php if ($contact->contact_pager): ?>
<?= $this->escape($contact->contact_pager) ?> <?= $this->escape($contact->contact_pager) ?>
<?php endif; ?> <?php endif ?>
</td> </td>
<?php if ($contact->contact_notify_service_timeperiod): ?> <?php if ($contact->contact_notify_service_timeperiod): ?>
<td> <td>
<?= $this->escape($contact->contact_notify_service_timeperiod) ?> <?= $this->escape($contact->contact_notify_service_timeperiod) ?>
</td> </td>
<?php endif; ?> <?php endif ?>
<?php if ($contact->contact_notify_host_timeperiod): ?> <?php if ($contact->contact_notify_host_timeperiod): ?>
<td> <td>
<?= $this->escape($contact->contact_notify_host_timeperiod) ?> <?= $this->escape($contact->contact_notify_host_timeperiod) ?>
</td> </td>
<?php endif; ?> <?php endif ?>
</tr> </tr>
<?php endforeach ?> <?php endforeach ?>
</tbody> </tbody>
</table> </table>
<?php if ($contacts->hasMore()): ?> <?php if ($contacts->hasMore()): ?>
<div class="action-links">
<?= $this->qlink( <?= $this->qlink(
$this->translate('Show More'), $this->translate('Show More'),
$this->url()->without(array('view', 'limit')), $this->url()->without(array('view', 'limit')),
null, null,
array( array(
'data-base-target' => '_next', 'class' => 'action-link',
'class' => 'pull-right action-link' 'data-base-target' => '_next'
) )
); ?> ) ?>
<?php endif ?> </div>
<?php else: ?>
<?= $this->translate('No contacts found matching the filter'); ?>
<?php endif ?> <?php endif ?>
</div> </div>