mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-31 01:34:09 +02:00
Restyle resources config
This commit is contained in:
parent
5c27f8153a
commit
4fef863674
@ -1,37 +1,30 @@
|
|||||||
<?php
|
|
||||||
use Icinga\Web\Url;
|
|
||||||
$createResource = $this->href('/config/createresource');
|
|
||||||
?>
|
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
<?= $this->tabs->render($this); ?>
|
<?= $this->tabs ?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="content">
|
<div class="content" data-base-target="col2">
|
||||||
<?php if (isset($this->messageBox)): ?>
|
<?php
|
||||||
<?= $this->messageBox->render() ?>
|
|
||||||
<?php endif ?>
|
|
||||||
|
|
||||||
<h1>Create Resource</h1>
|
if (isset($this->messageBox)) {
|
||||||
<p><a href="<?= $createResource ?>"><?= $this->icon('create.png'); ?> Create A New Resource</a></p>
|
// TODO: Get rid of messageBoxes in favour of notifications
|
||||||
|
echo $this->messageBox->render();
|
||||||
|
}
|
||||||
|
|
||||||
<table class="configTable">
|
?>
|
||||||
<?php foreach ($this->resources as $name => $resource): ?>
|
<p><a href="<?= $this->href('/config/createresource') ?>"><?= $this->icon('create.png'); ?> Create A New Resource</a></p>
|
||||||
<tr>
|
|
||||||
<td class="configTable">
|
<table class="action">
|
||||||
<div>
|
<thead>
|
||||||
<b>Resource:</b> <?= $this->escape($name); ?>
|
<th>Resource</th>
|
||||||
</div>
|
<th style="width: 5em">Remove</th>
|
||||||
<div>
|
</thead>
|
||||||
<a href="<?= $this->href('config/editresource', array('resource' => $name));?>">
|
<tbody>
|
||||||
<?= $this->icon('edit.png'); ?> Edit</a> 
|
<?php foreach ($this->resources as $name => $resource): ?>
|
||||||
<?php if (count($this->resources) > 1): ?>
|
<tr>
|
||||||
<a href="<?= $this->href('config/removeresource', array('resource' => $name));?>">
|
<td><a href="<?= $this->href('config/editresource', array('resource' => $name)) ?>"><?= $this->icon('edit.png') ?> <?= $this->escape($name); ?></td>
|
||||||
<?= $this->icon('remove.png'); ?> Remove</a> 
|
<td style="text-align: center"><a href="<?= $this->href('config/removeresource', array('resource' => $name)) ?>"><?= $this->icon('remove.png'); ?></a></td>
|
||||||
<?php endif; ?>
|
</tr>
|
||||||
</div>
|
<?php endforeach; ?>
|
||||||
</td>
|
</table>
|
||||||
</tr>
|
|
||||||
<?php endforeach; ?>
|
|
||||||
</table>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user