diff --git a/application/views/scripts/group/list.phtml b/application/views/scripts/group/list.phtml index 9b1b545d2..3d9afd9b4 100644 --- a/application/views/scripts/group/list.phtml +++ b/application/views/scripts/group/list.phtml @@ -1,4 +1,9 @@ -compact): ?> +compact): ?>
tabs; ?> sortBox; ?> @@ -10,12 +15,15 @@
-
+
translate('No backend found which is able to list groups') . '
'; return; +} else { + $extensible = $backend instanceof Extensible; + $reducible = $backend instanceof Reducible; } if (! isset($groups)) { @@ -23,12 +31,7 @@ if (! isset($groups)) { return; } -if (count($groups) === 0) { - echo $this->translate('No groups found matching the filter') . '
'; - return; -} -?> - +if (count($groups) > 0): ?> @@ -36,6 +39,9 @@ if (count($groups) === 0) { + + + @@ -51,8 +57,34 @@ if (count($groups) === 0) { + + +
translate('Parent'); ?> translate('Created at'); ?> translate('Last modified'); ?>translate('Remove'); ?>
last_modified === null ? $this->translate('Never') : date('d/m/Y g:i A', $group->last_modified); ?> + qlink( + null, + 'group/remove', + array( + 'backend' => $backend->getName(), + 'group' => $group->group_name + ), + array( + 'title' => sprintf($this->translate('Remove group %s'), $group->group_name), + 'icon' => 'trash' + ) + ); ?> +
+ +

translate('No groups found matching the filter'); ?>

+ + +qlink($this->translate('Add a new group'), 'group/add', array('backend' => $backend->getName()), array( + 'icon' => 'plus', + 'data-base-target' => '_next', + 'class' => 'group-add' +)); ?> + \ No newline at end of file diff --git a/public/css/icinga/main-content.less b/public/css/icinga/main-content.less index ac4549d1e..032e7df24 100644 --- a/public/css/icinga/main-content.less +++ b/public/css/icinga/main-content.less @@ -223,23 +223,29 @@ table.user-list { } } -table.group-list { - th { - &.group-parent { - width: 6%; - padding-right: 0.5em; - text-align: right; +div.content.groups { + table.group-list { + th { + &.group-parent, &.group-remove { + width: 6%; + padding-right: 0.5em; + text-align: right; + } + + &.group-created, &.group-modified { + width: 12%; + padding-right: 0.5em; + text-align: right; + } } - &.group-created, &.group-modified { - width: 12%; - padding-right: 0.5em; + td.group-parent, td.group-created, td.group-modified, td.group-remove { text-align: right; } } - td.group-parent, td.group-created, td.group-modified { - text-align: right; + p { + margin-top: 0; } }