mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-27 07:44:04 +02:00
Pass event instead of object to the getHtmlForEvent method of EventDetailsExtensionHook
This commit is contained in:
parent
688e3fd6e5
commit
89fdccb858
@ -83,7 +83,7 @@ class EventController extends Controller
|
|||||||
/** @var EventDetailsExtensionHook $hook */
|
/** @var EventDetailsExtensionHook $hook */
|
||||||
foreach (Hook::all('Monitoring\\EventDetailsExtension') as $hook) {
|
foreach (Hook::all('Monitoring\\EventDetailsExtension') as $hook) {
|
||||||
try {
|
try {
|
||||||
$html = $hook->getHtmlForEvent($object);
|
$html = $hook->getHtmlForEvent($event);
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
$html = $this->view->escape($e->getMessage());
|
$html = $this->view->escape($e->getMessage());
|
||||||
}
|
}
|
||||||
|
@ -41,7 +41,7 @@ abstract class EventDetailsExtensionHook
|
|||||||
/**
|
/**
|
||||||
* Shall return valid HTML to include in the detail view
|
* Shall return valid HTML to include in the detail view
|
||||||
*
|
*
|
||||||
* @param object $object The object to generate HTML for
|
* @param object $event The object to generate HTML for
|
||||||
*
|
*
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user