mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-10-25 01:14:29 +02:00
21 lines
519 B
PHP
21 lines
519 B
PHP
<?php
|
|
|
|
use Icinga\Module\Director\ActionController;
|
|
|
|
use Icinga\Module\Director\IcingaConfig\IcingaConfig;
|
|
|
|
class Director_ConfigController extends ActionController
|
|
{
|
|
public function showAction()
|
|
{
|
|
$this->view->config = IcingaConfig::fromDb(pack('H*', $this->params->get('checksum')), $this->db());
|
|
}
|
|
|
|
public function storeAction()
|
|
{
|
|
/** @var IcingaConfig $config */
|
|
$config = IcingaConfig::generate($this->db());
|
|
$this->view->id = $config->getHexChecksum();
|
|
}
|
|
}
|