Revert "Adjust command links so that they'll use `host_name' instead of `host'"

This reverts commit b9aee47d1f.

Conflicts:
	modules/monitoring/application/views/scripts/list/comments.phtml
	modules/monitoring/application/views/scripts/list/downtimes.phtml
This commit is contained in:
Johannes Meyer 2015-04-20 16:11:08 +02:00
parent 96fb0370a4
commit 894457a1c1
8 changed files with 16 additions and 16 deletions

View File

@ -87,11 +87,11 @@ if (count($comments) === 0) {
$delCommentForm->populate(array('comment_id' => $comment->id, 'redirect' => $this->url));
if ($comment->objecttype === 'host') {
$delCommentForm->setAction(
$this->url('monitoring/host/delete-comment', array('host_name' => $comment->host_name))
$this->url('monitoring/host/delete-comment', array('host' => $comment->host_name))
);
} else {
$delCommentForm->setAction($this->url('monitoring/service/delete-comment', array(
'host_name' => $comment->host_name,
'host' => $comment->host_name,
'service' => $comment->service_description
)));
}

View File

@ -114,10 +114,10 @@ if (count($downtimes) === 0) {
$delDowntimeForm = clone $delDowntimeForm;
$delDowntimeForm->populate(array('downtime_id' => $downtime->id, 'redirect' => $this->url));
if (! $isService) {
$delDowntimeForm->setAction($this->url('monitoring/host/delete-downtime', array('host_name' => $downtime->host_name)));
$delDowntimeForm->setAction($this->url('monitoring/host/delete-downtime', array('host' => $downtime->host_name)));
} else {
$delDowntimeForm->setAction($this->url('monitoring/service/delete-downtime', array(
'host_name' => $downtime->host_name,
'host' => $downtime->host_name,
'service' => $downtime->service_description
)));
}

View File

@ -26,12 +26,12 @@ if ($object->acknowledged): ?>
if ($object->getType() === $object::TYPE_HOST) {
$ackLink = $this->href(
'monitoring/host/acknowledge-problem',
array('host_name' => $object->getName())
array('host' => $object->getName())
);
} else {
$ackLink = $this->href(
'monitoring/service/acknowledge-problem',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName())
array('host' => $object->getHost()->getName(), 'service' => $object->getName())
);
}
?>

View File

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

View File

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

View File

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

View File

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

View File

@ -5,12 +5,12 @@
if ($object->getType() === $object::TYPE_HOST) {
$ackLink = $this->href(
'monitoring/host/send-custom-notification',
array('host_name' => $object->getName())
array('host' => $object->getName())
);
} else {
$ackLink = $this->href(
'monitoring/service/send-custom-notification',
array('host_name' => $object->getHost()->getName(), 'service' => $object->getName())
array('host' => $object->getHost()->getName(), 'service' => $object->getName())
);
}
?>