Style monitored objects' detailview extensions as expected

refs #2949
This commit is contained in:
Alexander A. Klimov 2017-09-07 15:11:03 +02:00
parent c2ee3bef06
commit 467fc79095
1 changed files with 4 additions and 1 deletions

View File

@ -84,7 +84,10 @@ abstract class MonitoredObjectController extends Controller
$this->view->extensionsHtml = array(); $this->view->extensionsHtml = array();
foreach (Hook::all('Monitoring\DetailviewExtension') as $hook) { foreach (Hook::all('Monitoring\DetailviewExtension') as $hook) {
/** @var DetailviewExtensionHook $hook */ /** @var DetailviewExtensionHook $hook */
$this->view->extensionsHtml[] = $hook->setView($this->view)->getHtmlForObject($this->object); $this->view->extensionsHtml[] =
'<div class="icinga-module module-' . $this->view->escape($hook->getModule()->getName()) . '">'
. $hook->setView($this->view)->getHtmlForObject($this->object)
. '</div>';
} }
} }