icingaweb2-module-director/application/controllers/TimeperiodtemplateController.php
Thomas Gelf dac5dbdcc0 TemplateUsage: make code generic, do no longer...
...require concrete implementations

fixes #1028
fixes #1032
2017-07-27 11:34:12 +02:00

17 lines
410 B
PHP

<?php
namespace Icinga\Module\Director\Controllers;
use Icinga\Module\Director\Objects\IcingaTimePeriod;
use Icinga\Module\Director\Web\Controller\TemplateController;
class TimeperiodtemplateController extends TemplateController
{
protected function requireTemplate()
{
return IcingaTimePeriod::load([
'object_name' => $this->params->get('name')
], $this->db());
}
}