setName('setup_monitoring_backend'); } public function createElements(array $formData) { $this->addElement( new Note( 'description', array( 'value' => mt( 'monitoring', 'Please configure below how Icinga Web 2 should retrieve monitoring information.' ) ) ) ); $this->addElement( 'text', 'name', array( 'required' => true, 'label' => mt('monitoring', 'Backend Name'), 'description' => mt('monitoring', 'The identifier of this backend') ) ); $resourceTypes = array(); if (Platform::extensionLoaded('mysql') || Platform::extensionLoaded('pgsql')) { $resourceTypes['ido'] = 'IDO'; } $resourceTypes['livestatus'] = 'Livestatus'; $this->addElement( 'select', 'type', array( 'required' => true, 'label' => mt('monitoring', 'Backend Type'), 'description' => mt('monitoring', 'The data source used for retrieving monitoring information'), 'multiOptions' => $resourceTypes ) ); } }