Mini Shell

Direktori : /opt/bakmgr/lib64/python3.6/site-packages/bakmgr/dash/templates/
Upload File :
Current File : //opt/bakmgr/lib64/python3.6/site-packages/bakmgr/dash/templates/list_restores.html.jinja

{# vim: ts=2:sw=2:et:ft=jinja-html #}
{% from "bootstrap_macros.html.jinja" import header_card without context %}

{% macro restore(name, data, class="") %}
<div class="card {{ class }}">
  <div class="card-header">
    <button class="btn btn-secondary btn-sm" onclick="dismiss('{{ name }}', 'name');">Dismiss</button>
    {% if data['success'] %}
      <span class="text-success">Success:</span>
    {% else %}
      <span class="text-warning">Failed:</span>
    {% endif %}
    {{ data['task'].title() }} from {{ data['date'] }}
  </div>
  <div class="card-body">
    <pre>{{ data['log'] | join('\n') }}</pre>
  </div>
</div>
{% endmacro %}

{% call header_card("Completed and Running Restores") %}
  {% if pids %}
    Restores running with PIDs:
    <ul class="list-group">
      {% for pid in pids %}
        <li class="list-group-item">
          <button class="btn btn-danger btn-sm" onclick="dismiss({{ pid }}, 'pid');">Stop</button>
          {{ pid }}
        </li>
      {% endfor %}
    </ul>
  {% else %}
    <p>No running restores found.</p>
  {% endif %}
<div class="mt-3">
  {% if finished %}
    {% for name, data in finished.items() %}
      {{ restore(name, data, '' if loop.first else 'mt-3') }}
    {% endfor %}
  {% else %}
    <p>No completed restores found.</p>
  {% endif %}
{% endcall %}
</div>

Zerion Mini Shell 1.0