diff --git a/application/controllers/ConfigController.php b/application/controllers/ConfigController.php index ffa87f035..eb8220fa9 100644 --- a/application/controllers/ConfigController.php +++ b/application/controllers/ConfigController.php @@ -375,13 +375,15 @@ class ConfigController extends BaseConfigController $this->render('authentication/remove'); } - public function resourceAction($showOnly = false) + /** + * Display all available resources and a link to create a new one + */ + public function resourceAction() { + $this->view->messageBox = new AlertMessageBox(true); $this->view->tabs->activate('resources'); - $this->view->messageBox = new AlertMessageBox(true); $this->view->resources = IcingaConfig::app('resources', true)->toArray(); - $this->render('resource'); } public function createresourceAction() diff --git a/application/views/scripts/config/resource.phtml b/application/views/scripts/config/resource.phtml index 2e0d95234..8e2c2eedd 100644 --- a/application/views/scripts/config/resource.phtml +++ b/application/views/scripts/config/resource.phtml @@ -1,30 +1,33 @@
-tabs ?> +
-
-messageBox)) { - // TODO: Get rid of messageBoxes in favour of notifications - echo $this->messageBox->render(); -} - -?> -

icon('create.png'); ?> Create A New Resource

- - - - - - - + +

+ + icon('create.png'); ?> translate('Create a new resource'); ?> + +

+
ResourceRemove
+ + + + + resources as $name => $resource): ?> - - - - + + + + -
translate('Resource'); ?>translate('Remove'); ?>
icon('edit.png') ?> escape($name); ?>icon('remove.png'); ?>
+ + icon('edit.png') ?> escape($name); ?> + + + + icon('remove.png'); ?> + +
-
- + + + \ No newline at end of file