monitoring: Use host and service display_name for displaying host and service names for an object's history

refs #7843
This commit is contained in:
Eric Lippmann 2015-01-22 10:57:44 +01:00
parent 1aa91f0228
commit 4589621f58
1 changed files with 12 additions and 7 deletions

View File

@ -136,13 +136,18 @@ $output = $this->tickets ? preg_replace_callback(
?>
<?php if ($isService): ?>
<?= $hostContext ? $this->qlink(
$this->escape($event->service_description),
'monitoring/show/service',
array(
'host' => $event->host_name,
'service' => $event->service_description)
) : $this->escape($event->service_description); ?> <?= $this->translate('on') . ' ' . $this->escape($event->host_name); ?>
<?= sprintf(
$this->translate('%s on %s', 'Service running on host'),
$hostContext ? $this->qlink(
$this->escape($event->service_display_name),
'monitoring/show/service',
array(
'host' => $event->host_name,
'service' => $event->service_description
)
) : $this->escape($event->service_display_name),
$event->host_display_name
) ?>
<?php else: ?>
<?= $this->escape($event->host_name); ?>
<?php endif ?>