Browse Source

Frequency -> Period, messaging on welcome page.

pull/7/head
Pēteris Caune 9 years ago
parent
commit
d8828b2d25
6 changed files with 26 additions and 28 deletions
  1. +4
    -4
      static/css/style.css
  2. +5
    -5
      static/js/checks.js
  3. +1
    -1
      templates/emails/alert/body.html
  4. +5
    -5
      templates/front/docs.html
  5. +6
    -6
      templates/front/my_checks.html
  6. +5
    -7
      templates/front/welcome.html

+ 4
- 4
static/css/style.css View File

@ -157,7 +157,7 @@ td.inactive .popover {
margin-left: -77px; margin-left: -77px;
} }
#checks-table > tbody > tr > th.th-frequency {
#checks-table > tbody > tr > th.th-period {
padding-left: 15px; padding-left: 15px;
} }
@ -209,11 +209,11 @@ tr:hover .check-menu {
} }
#frequency-slider {
#period-slider {
margin: 20px 50px 80px 50px; margin: 20px 50px 80px 50px;
} }
#frequency-slider.noUi-connect {
#period-slider.noUi-connect {
background: #5cb85c; background: #5cb85c;
} }
@ -225,7 +225,7 @@ tr:hover .check-menu {
background: #f0ad4e; background: #f0ad4e;
} }
#frequency-slider .noUi-value, #grace-slider .noUi-value {
#period-slider .noUi-value, #grace-slider .noUi-value {
width: 60px; width: 60px;
margin-left: -30px; margin-left: -30px;
} }


+ 5
- 5
static/js/checks.js View File

@ -16,8 +16,8 @@ $(function () {
return result; return result;
} }
var frequencySlider = document.getElementById("frequency-slider");
noUiSlider.create(frequencySlider, {
var periodSlider = document.getElementById("period-slider");
noUiSlider.create(periodSlider, {
start: [20], start: [20],
connect: "lower", connect: "lower",
range: { range: {
@ -37,9 +37,9 @@ $(function () {
} }
}); });
frequencySlider.noUiSlider.on("update", function(a, b, value) {
periodSlider.noUiSlider.on("update", function(a, b, value) {
var rounded = Math.round(value); var rounded = Math.round(value);
$("#frequency-slider-value").text(secsToText(rounded));
$("#period-slider-value").text(secsToText(rounded));
$("#update-timeout-timeout").val(rounded); $("#update-timeout-timeout").val(rounded);
}); });
@ -88,7 +88,7 @@ $(function () {
var $this = $(this); var $this = $(this);
$("#update-timeout-form").attr("action", $this.data("url")); $("#update-timeout-form").attr("action", $this.data("url"));
frequencySlider.noUiSlider.set($this.data("timeout"))
periodSlider.noUiSlider.set($this.data("timeout"))
graceSlider.noUiSlider.set($this.data("grace")) graceSlider.noUiSlider.set($this.data("grace"))
$('#update-timeout-modal').modal({"show":true, "backdrop":"static"}); $('#update-timeout-modal').modal({"show":true, "backdrop":"static"});


+ 1
- 1
templates/emails/alert/body.html View File

@ -41,7 +41,7 @@
<th></th> <th></th>
<th>Name</th> <th>Name</th>
<th>URL</th> <th>URL</th>
<th>Frequency</th>
<th>Period</th>
<th>Last Ping</th> <th>Last Ping</th>
</tr> </tr>
{% for check in checks %} {% for check in checks %}


+ 5
- 5
templates/front/docs.html View File

@ -40,7 +40,7 @@ curl {{ ping_endpoint }}{uuid-goes-here}
<h3>When Alerts Are Sent</h3> <h3>When Alerts Are Sent</h3>
<p> <p>
Each check has a configurable <strong>Frequency</strong> parameter, with the default value of one day.
Each check has a configurable <strong>Period</strong> parameter, with the default value of one day.
For periodic tasks, this is the expected time gap between two runs. For periodic tasks, this is the expected time gap between two runs.
</p> </p>
<p> <p>
@ -68,7 +68,7 @@ curl {{ ping_endpoint }}{uuid-goes-here}
</td> </td>
<td> <td>
<strong>Up.</strong> <strong>Up.</strong>
Time since last ping has not exceeded <strong>Frequency</strong>.
Time since last ping has not exceeded <strong>Period</strong>.
</td> </td>
</tr> </tr>
<tr> <tr>
@ -77,8 +77,8 @@ curl {{ ping_endpoint }}{uuid-goes-here}
</td> </td>
<td> <td>
<strong>Late.</strong> <strong>Late.</strong>
Time since last ping has exceeded <strong>Frequency</strong>,
but has not yet exceeded <strong>Frequency</strong> + <strong>Grace</strong>.
Time since last ping has exceeded <strong>Period</strong>,
but has not yet exceeded <strong>Period</strong> + <strong>Grace</strong>.
</td> </td>
</tr> </tr>
<tr> <tr>
@ -87,7 +87,7 @@ curl {{ ping_endpoint }}{uuid-goes-here}
</td> </td>
<td> <td>
<strong>Down.</strong> <strong>Down.</strong>
Time since last ping has exceeded <strong>Frequency</strong> + <strong>Grace</strong>.
Time since last ping has exceeded <strong>Period</strong> + <strong>Grace</strong>.
When check goes from "Late" to "Down", healthchecks.io When check goes from "Late" to "Down", healthchecks.io
sends you an email alert. sends you an email alert.
</td> </td>


+ 6
- 6
templates/front/my_checks.html View File

@ -14,8 +14,8 @@
<th></th> <th></th>
<th class="th-name">Name</th> <th class="th-name">Name</th>
<th>URL</th> <th>URL</th>
<th class="th-frequency">
Frequency <br />
<th class="th-period">
Period <br />
<span class="checks-subline">Grace</span> <span class="checks-subline">Grace</span>
</th> </th>
<th>Last Ping</th> <th>Last Ping</th>
@ -147,15 +147,15 @@
class="update-timeout-label" class="update-timeout-label"
data-toggle="tooltip" data-toggle="tooltip"
title="Expected time between pings."> title="Expected time between pings.">
Frequency
Period
</span> </span>
<span <span
id="frequency-slider-value"
id="period-slider-value"
class="update-timeout-value"> class="update-timeout-value">
1 day 1 day
</span> </span>
</div> </div>
<div id="frequency-slider"></div>
<div id="period-slider"></div>
<div class="update-timeout-info text-center"> <div class="update-timeout-info text-center">
<span <span
@ -175,7 +175,7 @@
<div class="update-timeout-terms"> <div class="update-timeout-terms">
<p> <p>
<span>Frequency</span>
<span>Period</span>
Expected time between pings. Expected time between pings.
</p> </p>
<p> <p>


+ 5
- 7
templates/front/welcome.html View File

@ -6,7 +6,7 @@
<div class="container"> <div class="container">
<div class="row"> <div class="row">
<div class="col-sm-12"> <div class="col-sm-12">
<h1 id="pitch">Get Notified When Your Cron Jobs Fail</h1>
<h1 id="pitch">Cron Monitoring. Get Notified When Your Cron Jobs Fail</h1>
</div> </div>
</div> </div>
@ -71,7 +71,7 @@
<table class="table"> <table class="table">
<tr> <tr>
<th>Last ping</th> <th>Last ping</th>
<th>Frequency</th>
<th>Period</th>
<th>Alert in</th> <th>Alert in</th>
</tr> </tr>
<tr> <tr>
@ -82,11 +82,9 @@
Never Never
{% endif %} {% endif %}
</td> </td>
<td>1 day
<span
class="glyphicon glyphicon-question-sign"
data-toggle="tooltip"
title="Sign in to change frequency"></span>
<td>
1 day
(log in to change)
</td> </td>
<td id="timer" data-timer="{{ timer}}"> <td id="timer" data-timer="{{ timer}}">
{{ timer_formatted }} {{ timer_formatted }}


Loading…
Cancel
Save