summaryrefslogtreecommitdiffstats
path: root/configuration.php
diff options
context:
space:
mode:
Diffstat (limited to 'configuration.php')
-rw-r--r--configuration.php46
1 files changed, 46 insertions, 0 deletions
diff --git a/configuration.php b/configuration.php
new file mode 100644
index 0000000..0147b89
--- /dev/null
+++ b/configuration.php
@@ -0,0 +1,46 @@
+<?php
+/** @var Icinga\Application\Modules\Module $this */
+
+$config = $this->getConfig();
+
+$url = 'eventdb/events';
+if (($default_filter = $config->get('global', 'default_filter')) !== null) {
+ $url .= '?' . $default_filter;
+}
+
+$section = $this->menuSection('EventDB', array(
+ 'icon' => 'tasks',
+ 'priority' => 200,
+ 'url' => $url,
+));
+
+$this->provideConfigTab('config', array(
+ 'title' => $this->translate('Configure EventDB'),
+ 'label' => $this->translate('Config'),
+ 'url' => 'config'
+));
+$this->provideConfigTab('monitoring', array(
+ 'title' => $this->translate('Configure integration into the monitoring module'),
+ 'label' => $this->translate('Monitoring'),
+ 'url' => 'config/monitoring'
+));
+
+$this->providePermission(
+ 'eventdb/events',
+ $this->translate('Allow to view events')
+);
+
+$this->providePermission(
+ 'eventdb/comments',
+ $this->translate('Allow to view comments')
+);
+
+$this->providePermission(
+ 'eventdb/interact',
+ $this->translate('Allow to acknowledge and comment events')
+);
+
+$this->provideRestriction(
+ 'eventdb/events/filter',
+ $this->translate('Restrict views to the events that match the filter')
+);