Adjust command links so that they'll use `service_description'

...instead of `service'

refs #8613
This commit is contained in:
Johannes Meyer 2015-04-09 10:28:34 +02:00
parent b9aee47d1f
commit cee189a5fc
8 changed files with 14 additions and 8 deletions

View File

@ -83,7 +83,10 @@
if ($comment->objecttype === 'host') { if ($comment->objecttype === 'host') {
$delCommentForm->setAction($this->url('monitoring/host/delete-comment', array('host_name' => $comment->host))); $delCommentForm->setAction($this->url('monitoring/host/delete-comment', array('host_name' => $comment->host)));
} else { } else {
$delCommentForm->setAction($this->url('monitoring/service/delete-comment', array('host_name' => $comment->host, 'service' => $comment->service))); $delCommentForm->setAction($this->url('monitoring/service/delete-comment', array(
'host_name' => $comment->host,
'service_description' => $comment->service
)));
} }
echo $delCommentForm; echo $delCommentForm;
?> ?>

View File

@ -122,7 +122,10 @@ use Icinga\Module\Monitoring\Object\Service;
if (! isset($downtime->service)) { if (! isset($downtime->service)) {
$delDowntimeForm->setAction($this->url('monitoring/host/delete-downtime', array('host_name' => $downtime->host))); $delDowntimeForm->setAction($this->url('monitoring/host/delete-downtime', array('host_name' => $downtime->host)));
} else { } else {
$delDowntimeForm->setAction($this->url('monitoring/service/delete-downtime', array('host_name' => $downtime->host, 'service' => $downtime->service))); $delDowntimeForm->setAction($this->url('monitoring/service/delete-downtime', array(
'host_name' => $downtime->host,
'service_description' => $downtime->service
)));
} }
echo $delDowntimeForm; echo $delDowntimeForm;
?> ?>

View File

@ -31,7 +31,7 @@ if ($object->acknowledged): ?>
} else { } else {
$ackLink = $this->href( $ackLink = $this->href(
'monitoring/service/acknowledge-problem', 'monitoring/service/acknowledge-problem',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName()) array('host_name' => $object->getHost()->getName(), 'service_description' => $object->getName())
); );
} }
?> ?>

View File

@ -31,7 +31,7 @@ if ($object->getType() === $object::TYPE_HOST) {
echo $this->qlink( echo $this->qlink(
$this->translate('Reschedule'), $this->translate('Reschedule'),
'monitoring/service/reschedule-check', 'monitoring/service/reschedule-check',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName()), array('host_name' => $object->getHost()->getName(), 'service_description' => $object->getName()),
array( array(
'icon' => 'reschedule', 'icon' => 'reschedule',
'data-base-target' => '_self', 'data-base-target' => '_self',

View File

@ -26,7 +26,7 @@ $command = array_shift($parts);
echo $this->qlink( echo $this->qlink(
$this->translate('Process check result'), $this->translate('Process check result'),
'monitoring/service/process-check-result', 'monitoring/service/process-check-result',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName()), array('host_name' => $object->getHost()->getName(), 'service_description' => $object->getName()),
array( array(
'icon' => 'reply', 'icon' => 'reply',
'data-base-target' => '_self', 'data-base-target' => '_self',

View File

@ -18,7 +18,7 @@
echo $this->qlink( echo $this->qlink(
$this->translate('Add comment'), $this->translate('Add comment'),
'monitoring/service/add-comment', 'monitoring/service/add-comment',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName()), array('host_name' => $object->getHost()->getName(), 'service_description' => $object->getName()),
array( array(
'icon' => 'comment', 'icon' => 'comment',
'data-base-target' => '_self', 'data-base-target' => '_self',

View File

@ -20,7 +20,7 @@
echo $this->qlink( echo $this->qlink(
$this->translate('Schedule downtime'), $this->translate('Schedule downtime'),
'monitoring/service/schedule-downtime', 'monitoring/service/schedule-downtime',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName()), array('host_name' => $object->getHost()->getName(), 'service_description' => $object->getName()),
array( array(
'icon' => 'plug', 'icon' => 'plug',
'data-base-target' => '_self', 'data-base-target' => '_self',

View File

@ -10,7 +10,7 @@
} else { } else {
$ackLink = $this->href( $ackLink = $this->href(
'monitoring/service/send-custom-notification', 'monitoring/service/send-custom-notification',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName()) array('host_name' => $object->getHost()->getName(), 'service_description' => $object->getName())
); );
} }
?> ?>