From b226ed13414b6dc165d17aa52c05cccdc4ffd27b Mon Sep 17 00:00:00 2001 From: Thomas Gelf Date: Fri, 13 Jan 2017 16:10:55 +0100 Subject: [PATCH] ServiceController: provide a link back for... ...services on hosts --- application/controllers/ServiceController.php | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/application/controllers/ServiceController.php b/application/controllers/ServiceController.php index 12291cf7..03b80a57 100644 --- a/application/controllers/ServiceController.php +++ b/application/controllers/ServiceController.php @@ -114,6 +114,15 @@ class ServiceController extends ObjectController { $object = $this->object; + if ($this->host) { + $this->view->actionLinks = $this->view->qlink( + $this->translate('back'), + 'director/host/services', + array('name' => $this->host->object_name), + array('class' => 'icon-left-big') + ); + } + if ($this->host && $object->usesVarOverrides()) { $parent = IcingaService::create(array( @@ -125,12 +134,6 @@ class ServiceController extends ObjectController $object->vars = $this->host->getOverriddenServiceVars($object->object_name); $object->imports()->add($parent); - $this->view->actionLinks = $this->view->qlink( - $this->translate('back'), - 'director/host/services', - array('name' => $this->host->object_name), - array('class' => 'icon-left-big') - ); } $this->getTabs()->activate('modify');