-
Notifications
You must be signed in to change notification settings - Fork 275
/
list.phtml
56 lines (56 loc) · 1.89 KB
/
list.phtml
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
49
50
51
52
53
54
55
56
<div class="controls">
<?= $tabs ?>
</div>
<div class="content">
<?= $this->qlink(
$this->translate('Create A New Role') ,
'role/add',
null,
array(
'class' => 'button action-link',
'icon' => 'plus',
'title' => $this->translate('Create a new role')
)
) ?>
<?php /** @var \Icinga\Application\Config $roles */ if ($roles->isEmpty()): ?>
<p><?= $this->translate('No roles found.') ?></p>
<?php return; endif ?>
<table class="action-table listing-table" data-base-target="_next">
<thead>
<tr>
<th><?= $this->translate('Name') ?></th>
<th><?= $this->translate('Users') ?></th>
<th><?= $this->translate('Groups') ?></th>
<th></th>
</tr>
</thead>
<tbody>
<?php foreach ($roles as $name => $role): /** @var object $role */ ?>
<tr>
<td>
<?= $this->qlink(
$name,
'role/edit',
array('role' => $name),
array('title' => sprintf($this->translate('Edit role %s'), $name))
) ?>
</td>
<td><?= $this->escape($role->users) ?></td>
<td><?= $this->escape($role->groups) ?></td>
<td class="text-right">
<?= $this->qlink(
'',
'role/remove',
array('role' => $name),
array(
'class' => 'action-link',
'icon' => 'cancel',
'title' => sprintf($this->translate('Remove role %s'), $name)
)
) ?>
</td>
</tr>
<?php endforeach ?>
</tbody>
</table>
</div>