mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 16:54:04 +02:00
parent
45bf071db6
commit
67e935557e
@ -9,6 +9,7 @@ use Icinga\Module\Monitoring\Forms\Command\Object\ScheduleHostCheckCommandForm;
|
|||||||
use Icinga\Module\Monitoring\Forms\Command\Object\ScheduleHostDowntimeCommandForm;
|
use Icinga\Module\Monitoring\Forms\Command\Object\ScheduleHostDowntimeCommandForm;
|
||||||
use Icinga\Module\Monitoring\Object\Host;
|
use Icinga\Module\Monitoring\Object\Host;
|
||||||
use Icinga\Module\Monitoring\Web\Controller\MonitoredObjectController;
|
use Icinga\Module\Monitoring\Web\Controller\MonitoredObjectController;
|
||||||
|
use Icinga\Web\Hook;
|
||||||
|
|
||||||
class Monitoring_HostController extends MonitoredObjectController
|
class Monitoring_HostController extends MonitoredObjectController
|
||||||
{
|
{
|
||||||
@ -37,6 +38,28 @@ class Monitoring_HostController extends MonitoredObjectController
|
|||||||
$this->getTabs()->activate('host');
|
$this->getTabs()->activate('host');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected function getHostActions()
|
||||||
|
{
|
||||||
|
$urls = array();
|
||||||
|
|
||||||
|
foreach (Hook::all('Monitoring\\HostActions') as $hook) {
|
||||||
|
foreach ($hook->getActionsForHost($this->object) as $id => $url) {
|
||||||
|
$urls[$id] = $url;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return $urls;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Show a host
|
||||||
|
*/
|
||||||
|
public function showAction()
|
||||||
|
{
|
||||||
|
$this->view->hostActions = $this->getHostActions();
|
||||||
|
parent::showAction();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Acknowledge a host problem
|
* Acknowledge a host problem
|
||||||
*/
|
*/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user