26 lines
1.6 KiB
HTML
26 lines
1.6 KiB
HTML
{% for checker in set.checkers.all %}
|
|
{% with status=checker.status %}
|
|
<form method="POST">
|
|
{% csrf_token %}
|
|
<input type="hidden" name="action" value="delete_checker">
|
|
<input type="hidden" name="checker_id" value="{{ checker.id }}">
|
|
<button type="button" class="btn text-info" data-bs-toggle="modal" data-bs-target="#modal-checker-{{ checker.id }}">{{ checker.name }}</button> <span class="badge bg-{% if status == 'Active' %}success{% else %}{% if status == 'Testing' %}info{% else %}danger{% endif %}{% endif %}">{{ status }}</span>{% if status != 'Testing' %}<button type="submit" class="btn btn-link" style="color: black;"><i class="fa fa-times"></i></button>{% endif %}<br>
|
|
</form>
|
|
{% endwith %}
|
|
<div class="modal fade" id="modal-checker-{{ checker.id }}" tabindex="-1" aria-labelledby="modal-default" style="display: none;" aria-hidden="true">
|
|
<div class="modal-dialog modal-dialog-centered" role="document">
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<h2 class="h6 modal-title">{{ checker.name }}</h2>
|
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
|
</div>
|
|
<div class="modal-body">
|
|
{{ checker.token }}
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-link text-gray-600 ms-auto" data-bs-dismiss="modal">Закрыть</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endfor %} |