view/helpers: add $this->widget()
This commit is contained in:
parent
a53f589a6b
commit
d63d8fe451
|
@ -3,8 +3,13 @@
|
|||
namespace Icinga\Web\View;
|
||||
|
||||
use Icinga\Authentication\Manager;
|
||||
use Icinga\Web\Widget;
|
||||
|
||||
$this->addHelperFunction('auth', function () {
|
||||
return Manager::getInstance();
|
||||
});
|
||||
|
||||
$this->addHelperFunction('widget', function ($name, $options) {
|
||||
return Widget::create($name, $options);
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue