parent
8276f19ab7
commit
ecd91d8bff
|
@ -6,6 +6,7 @@ use Icinga\Module\Director\Web\Controller\ObjectController;
|
|||
use Icinga\Module\Director\Objects\IcingaHost;
|
||||
use Icinga\Module\Director\Objects\IcingaNotification;
|
||||
use Icinga\Module\Director\Objects\IcingaService;
|
||||
use Icinga\Module\Director\Web\Form\DirectorObjectForm;
|
||||
|
||||
class NotificationController extends ObjectController
|
||||
{
|
||||
|
@ -33,6 +34,18 @@ class NotificationController extends ObjectController
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param DirectorObjectForm $form
|
||||
*/
|
||||
protected function beforeHandlingEditRequest($form)
|
||||
{
|
||||
if ($this->object->isTemplate()) {
|
||||
$form->setListUrl('director/notifications/templates');
|
||||
} else {
|
||||
$form->setListUrl('director/notifications/applyrules');
|
||||
}
|
||||
}
|
||||
|
||||
protected function loadObject()
|
||||
{
|
||||
if ($this->object === null) {
|
||||
|
|
Loading…
Reference in New Issue