-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfiguration.php
More file actions
48 lines (41 loc) · 1.11 KB
/
configuration.php
File metadata and controls
48 lines (41 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?php
use Icinga\Authentication\Auth;
$feedMenu = $this->menuSection('Feeds')
->setIcon('rss');
$auth = Auth::getInstance();
if ($auth->hasPermission('feeds/list')) {
$feedMenu->add('List')
->setIcon('edit')
->setUrl('feeds/feeds/list');
}
if ($auth->hasPermission('feeds/view')) {
$feedMenu->add('View')
->setIcon('bars')
->setUrl('feeds/feeds');
}
$this->provideConfigTab(
'general',
[
'title' => $this->translate('General'),
'label' => $this->translate('General'),
'url' => 'config/general'
]
);
$this->provideCssFile('item.less');
$this->provideCssFile('view-mode-switcher.less');
$this->providePermission(
'feeds/list',
$this->translate('Allow to see the list of configured feeds'),
);
$this->providePermission(
'feeds/view',
$this->translate('Allow to view configured feeds'),
);
$this->providePermission(
'feeds/view/arbitrary',
$this->translate('Allow to view an arbitrary feed by providing an URL'),
);
$this->providePermission(
'feeds/modify',
$this->translate('Allow creating and modifying feeds'),
);