forked from mwarkentin/django-watchman
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Drew Hubl
committed
Jun 17, 2015
1 parent
e443d84
commit 747941d
Showing
3 changed files
with
107 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
{% extends "base.html" %} | ||
|
||
{% load i18n %} | ||
|
||
{% block content %} | ||
<h2>System Status{% if overall_status == 'OK' %} <small>All systems up and running!</small>{% endif %}</h2> | ||
|
||
<table class="table table-bordered table-hover"> | ||
<thead> | ||
<tr> | ||
<th>{% trans 'Type' %}</th> | ||
<th>{% trans 'Name' %}</th> | ||
<th>{% trans 'Status' %}</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
{% for type in checks %} | ||
{% for thing in type.statuses %} | ||
<tr> | ||
<td class="{% if type.overall_status == 'OK' %}bg-success{% endif %}">{{ type.type|title }}</td> | ||
<td>{{ thing.name|title }}</td> | ||
|
||
{% if thing.status == 'OK' %} | ||
<td class="success">{{ thing.status }}</td> | ||
|
||
{% else %} | ||
<td class="danger"> | ||
<button type="button" class="btn btn-danger" data-toggle="modal" data-target="#{{ type.type }}-{{ thing.name }}">ERROR!</button> | ||
|
||
<div class="modal fade" id="{{ type.type }}-{{ thing.name }}" tabindex="-1" role="dialog" aria-labelledby="{{ type.type }}-{{ thing.name }}-title"> | ||
<div class="modal-dialog" role="document"> | ||
<div class="modal-content"> | ||
<div class="modal-header"> | ||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> | ||
<h4 class="modal-title" id="{{ type.type }}-{{ thing.name }}-title">{{ type.type|title }} - {{ thing.name|title }}</h4> | ||
</div><!-- class="modal-header" --> | ||
<div class="modal-body"> | ||
<h4><pre>{{ thing.error }}</pre></h4> | ||
<pre>{{ thing.traceback }}</pre> | ||
</div><!-- class="model-body" --> | ||
<div class="modal-footer"> | ||
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button> | ||
</div><!-- class="modal-footer" --> | ||
</div> | ||
</div> | ||
</div> | ||
</td> | ||
{% endif %}{# thing.status == 'OK' #} | ||
|
||
</tr> | ||
{% endfor %}{# for thing in type.statuses #} | ||
{% empty %} | ||
<tr> | ||
<td colspan="3">No checks indicated</td> | ||
</tr> | ||
{% endfor %}{# for type in checks #} | ||
</tbody> | ||
</table> | ||
|
||
<span class="pull-right"><small>Click an error button to see the full traceback</small></span> | ||
{% endblock %}{# status_content #} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters