{% extends "base.html" %}
|
|
{% load compress staticfiles %}
|
|
|
|
{% block title %}My Checks - healthchecks.io{% endblock %}
|
|
|
|
|
|
{% block content %}
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<h1>My Checks</h1>
|
|
{% if checks %}
|
|
{% include "front/my_checks_mobile.html" %}
|
|
{% include "front/my_checks_desktop.html" %}
|
|
{% else %}
|
|
<div class="alert alert-info">You don't have any checks yet.</div>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-sm-12"></div>
|
|
<form method="post" action="{% url 'hc-add-check' %}" class="text-center">
|
|
{% csrf_token %}
|
|
<input type="submit" class="btn btn-primary btn-lg" value="Add Check">
|
|
</form>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="update-name-modal" class="modal">
|
|
<div class="modal-dialog">
|
|
<form id="update-name-form" method="post">
|
|
{% csrf_token %}
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<button type="button" class="close" data-dismiss="modal">×</span></button>
|
|
<h4 class="update-timeout-title">Name</h4>
|
|
</div>
|
|
<div class="modal-body">
|
|
<p>Give this check a human-friendly name, so you can
|
|
easily recognize it later:</p>
|
|
<input
|
|
id="update-name-input"
|
|
name="name"
|
|
type="text"
|
|
value="---"
|
|
placeholder="unnamed"
|
|
class="input-name form-control" />
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
|
|
<button type="submit" class="btn btn-primary">Save</button>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="update-timeout-modal" class="modal">
|
|
<div class="modal-dialog">
|
|
<form id="update-timeout-form" method="post">
|
|
{% csrf_token %}
|
|
<input type="hidden" name="timeout" id="update-timeout-timeout" />
|
|
<input type="hidden" name="grace" id="update-timeout-grace" />
|
|
<div class="modal-content">
|
|
<div class="modal-body">
|
|
<div class="update-timeout-info text-center">
|
|
<span
|
|
class="update-timeout-label"
|
|
data-toggle="tooltip"
|
|
title="Expected time between pings.">
|
|
Period
|
|
</span>
|
|
<span
|
|
id="period-slider-value"
|
|
class="update-timeout-value">
|
|
1 day
|
|
</span>
|
|
</div>
|
|
<div id="period-slider"></div>
|
|
|
|
<div class="update-timeout-info text-center">
|
|
<span
|
|
class="update-timeout-label"
|
|
data-toggle="tooltip"
|
|
title="When check is late, how much time to wait until alert is sent">
|
|
Grace Time
|
|
</span>
|
|
<span
|
|
id="grace-slider-value"
|
|
class="update-timeout-value">
|
|
1 day
|
|
</span>
|
|
</div>
|
|
|
|
<div id="grace-slider"></div>
|
|
|
|
<div class="update-timeout-terms">
|
|
<p>
|
|
<span>Period</span>
|
|
Expected time between pings.
|
|
</p>
|
|
<p>
|
|
<span>Grace Time</span>
|
|
When a check is late, how much time to wait until alert is sent.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
|
|
<button type="submit" class="btn btn-primary">Save</button>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="remove-check-modal" class="modal">
|
|
<div class="modal-dialog">
|
|
<form id="remove-check-form" method="post">
|
|
{% csrf_token %}
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<button type="button" class="close" data-dismiss="modal">×</span></button>
|
|
<h4 class="remove-check-title">Remove Check <span class="remove-check-name"></h4>
|
|
</div>
|
|
<div class="modal-body">
|
|
<p>You are about to remove check
|
|
<strong class="remove-check-name">---</strong>.
|
|
</p>
|
|
<p>Once it's gone there is no "undo" and you cannot get
|
|
the old ping URL back.</p>
|
|
<p>Are you sure?</p>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
|
|
<button type="submit" class="btn btn-danger">Remove</button>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
{% endblock %}
|
|
|
|
{% block scripts %}
|
|
{% compress js %}
|
|
<script src="{% static 'js/jquery-2.1.4.min.js' %}"></script>
|
|
<script src="{% static 'js/bootstrap.min.js' %}"></script>
|
|
<script src="{% static 'js/nouislider.min.js' %}"></script>
|
|
<script src="{% static 'js/checks.js' %}"></script>
|
|
{% endcompress %}
|
|
{% endblock %}
|