New pages to control generation queue
This commit is contained in:
parent
8b3d771fd1
commit
5836a3c3d8
6 changed files with 139 additions and 6 deletions
10
onyx/tpl/bootstrap/admin/generation.tpl
Normal file
10
onyx/tpl/bootstrap/admin/generation.tpl
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
{extends file="admin/layout.tpl"}
|
||||
{block name=content}
|
||||
<h1>
|
||||
Génération
|
||||
</h1>
|
||||
{if isset($return)}
|
||||
<h2>Sortie</h2>
|
||||
<pre>{$return|escape}</pre>
|
||||
{/if}
|
||||
{/block}
|
||||
|
|
@ -16,7 +16,7 @@
|
|||
</ul>
|
||||
<a href="/{$SALT_ADMIN}/certificate/deleteca" class="btn btn-danger"
|
||||
onclick="return confirm('Êtes-vous sûr de vouloir supprimer ce certificat ?')">Supprimer</a>
|
||||
{elseif ! $cert_writable}
|
||||
{elseif empty($cert_writable)}
|
||||
<div class="alert alert-danger"><span class="glyphicon glyphicon-warning-sign"></span> Répertoire non accessible en écriture.</div>
|
||||
<a href="/{$SALT_ADMIN}/certificate/newca" class="btn btn-primary" disabled="disabled">Nouveau</a>
|
||||
{else}
|
||||
|
|
@ -41,7 +41,7 @@
|
|||
</ul>
|
||||
<a href="/{$SALT_ADMIN}/certificate/revokesrv" class="btn btn-danger"
|
||||
onclick="return confirm('Êtes-vous sûr de vouloir supprimer ce certificat ?')">Supprimer</a>
|
||||
{elseif ! $cert_writable}
|
||||
{elseif empty($cert_writable)}
|
||||
<div class="alert alert-danger"><span class="glyphicon glyphicon-warning-sign"></span> Répertoire non accessible en écriture.</div>
|
||||
<a href="/{$SALT_ADMIN}/certificate/newsrv" class="btn btn-primary" disabled="disabled">Nouveau</a>
|
||||
{else}
|
||||
|
|
@ -62,7 +62,7 @@
|
|||
<div class="form-group">
|
||||
<label class="sr-only" for="time">Temps :</label>
|
||||
<div class="input-group">
|
||||
<input type="input" class="form-control" id="time" name="time" value="240">
|
||||
<input type="input" class="form-control" id="time" name="time" value="{$DEF_TIME|default:240}">
|
||||
<span class="input-group-addon">minutes</span>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -73,4 +73,49 @@
|
|||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Génération</h3>
|
||||
</div>
|
||||
<div class="panel-body container">
|
||||
<div class="col-xs-4">
|
||||
<table class="table table-hover table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>File d'attente</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{foreach from=$queue item=itm key=k}
|
||||
<tr>
|
||||
<td{if $k == 2} class="{if $itm == "empty!"}warning{else}success{/if}"{/if}>
|
||||
{$itm}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="col-xs-4">
|
||||
<a href="/{$SALT_ADMIN}/generation/full" class="btn btn-default">Tout regénérer</a>
|
||||
<a href="/{$SALT_ADMIN}/generation/sync" class="btn btn-default">Synchro légère</a><br>
|
||||
<a href="/{$SALT_ADMIN}/generation/clear" class="btn btn-danger">Vider la file d'attente</a><br>
|
||||
<a href="/{$SALT_ADMIN}/generation/freeze" class="btn btn-danger">Freeze</a>
|
||||
<a href="/{$SALT_ADMIN}/generation/unfreeze" class="btn btn-success">Unfreeze</a>
|
||||
<form method="post" action="/{$SALT_ADMIN}/generation/team" role="form" class="form-inline">
|
||||
<div class="form-group">
|
||||
<input type="input" class="form-control" id="regenteam" name="team" placeholder="Team to regen">
|
||||
<button type="submit" class="btn btn-primary">Regénérer</button>
|
||||
</div>
|
||||
</form>
|
||||
<form method="post" action="/{$SALT_ADMIN}/generation/custom" role="form" class="form-inline">
|
||||
<div class="form-group">
|
||||
<input type="input" class="form-control" id="cmds" name="cmds" placeholder="Custom commands, : separated">
|
||||
<button type="submit" class="btn btn-warning">Envoyer</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
|
|
|
|||
Reference in a new issue