getRequest()->isApiRequest()) { $this->sendExport(); return; } $this->addTitle($this->translate('Sync rule')) ->setAutorefreshInterval(10) ->addAddLink( $this->translate('Add a new Sync Rule'), 'director/syncrule/add' )->tabs(new ImportTabs())->activate('syncrule'); (new SyncruleTable($this->db()))->renderTo($this); } /** * @throws \Icinga\Exception\ConfigurationError */ protected function sendExport() { $this->sendJson( $this->getResponse(), (new ImportExport($this->db()))->serializeAllSyncRules() ); } }