monitoring: Use display_name for displaying the host and service names in the comments overview

refs #7843
This commit is contained in:
Eric Lippmann 2015-01-21 16:12:37 +01:00
parent e933b9174c
commit cf391b056c
1 changed files with 6 additions and 14 deletions

View File

@ -50,21 +50,13 @@
</td>
<td>
<?php if ($comment->objecttype === 'service'): ?>
<?= $this->icon('conf'); ?> <a href="<?= $this->href('monitoring/service/show', array(
'host' => $comment->host,
'service' => $comment->service,
)); ?>">
<?= $comment->service; ?>
</a>
<small>
<?= $this->translate('on') . ' ' . $comment->host; ?>
</small>
<?= $this->icon('service') ?>
<?= $this->link()->service(
$comment->service, $comment->service_display_name, $comment->host, $comment->host_display_name
) ?>
<?php else: ?>
<?= $this->icon('host'); ?> <a href="<?= $this->href('monitoring/host/show', array(
'host' => $comment->host
)); ?>">
<?= $comment->host; ?>
</a>
<?= $this->icon('host') ?>
<?= $this->link()->host($comment->host, $comment->host_display_name) ?>
<?php endif ?>
<br>
<?= $this->icon('comment'); ?> <?= isset($comment->author)