forked from GithubBackups/healthchecks
Usage instructions in "My Checks" page
This commit is contained in:
parent
9a15fabd06
commit
5676f7e1e8
@ -61,3 +61,11 @@
|
|||||||
background-color: #eee;
|
background-color: #eee;
|
||||||
color: #555;
|
color: #555;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#show-usage-modal .modal-dialog {
|
||||||
|
width: 1100px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#show-usage-modal .tab-content {
|
||||||
|
margin-top: 15px;
|
||||||
|
}
|
@ -39,11 +39,6 @@ table.table tr > th.th-name {
|
|||||||
border: 1px dotted #AAA;
|
border: 1px dotted #AAA;
|
||||||
}
|
}
|
||||||
|
|
||||||
.url-cell {
|
|
||||||
font-size: small;
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
#checks-table > tbody > tr > th.th-period {
|
#checks-table > tbody > tr > th.th-period {
|
||||||
padding-left: 15px;
|
padding-left: 15px;
|
||||||
}
|
}
|
||||||
@ -79,18 +74,11 @@ tr:hover .check-menu {
|
|||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
#checks-table .placeholder, #checks-table .my-checks-url.off, #checks-table .my-checks-email.off {
|
.my-checks-url {
|
||||||
font-family: "Lucida Console", Monaco, monospace;
|
font-family: "Lucida Console", Monaco, monospace;
|
||||||
font-size: 11.7px;
|
font-size: 11.7px;
|
||||||
height: 0;
|
position: relative;
|
||||||
overflow: hidden;
|
line-height: 36px;
|
||||||
|
color: #333;
|
||||||
}
|
}
|
||||||
|
|
||||||
#checks-table .selectable {
|
|
||||||
font-family: "Lucida Console", Monaco, monospace;
|
|
||||||
font-size: 11.7px;
|
|
||||||
width: 100%;
|
|
||||||
border: 0;
|
|
||||||
cursor: text;
|
|
||||||
background: transparent;
|
|
||||||
}
|
|
||||||
|
@ -139,11 +139,6 @@ $(function () {
|
|||||||
$(".my-checks-email").removeClass("off");
|
$(".my-checks-email").removeClass("off");
|
||||||
});
|
});
|
||||||
|
|
||||||
$(".selectable").click(function() {
|
|
||||||
$(this).tooltip("hide");
|
|
||||||
this.select();
|
|
||||||
});
|
|
||||||
|
|
||||||
$("#my-checks-tags button").click(function() {
|
$("#my-checks-tags button").click(function() {
|
||||||
// .active has not been updated yet by bootstrap code,
|
// .active has not been updated yet by bootstrap code,
|
||||||
// so cannot use it
|
// so cannot use it
|
||||||
@ -181,4 +176,18 @@ $(function () {
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$(".my-checks-url").click(function(e) {
|
||||||
|
var a = e.target;
|
||||||
|
var url = a.getAttribute("href");
|
||||||
|
var email = a.getAttribute("data-email");
|
||||||
|
|
||||||
|
$(".ex", "#show-usage-modal").text(url);
|
||||||
|
$(".em", "#show-usage-modal").text(email);
|
||||||
|
|
||||||
|
$(a).tooltip("hide");
|
||||||
|
$("#show-usage-modal").modal("show");
|
||||||
|
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
@ -196,6 +196,84 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div id="show-usage-modal" class="modal">
|
||||||
|
<div class="modal-dialog">
|
||||||
|
<div class="modal-content">
|
||||||
|
<div class="modal-header">
|
||||||
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
|
<ul class="nav nav-pills" role="tablist">
|
||||||
|
<li class="active">
|
||||||
|
<a href="#crontab" data-toggle="tab">Crontab</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="#bash" data-toggle="tab">Bash</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="#python" data-toggle="tab">Python</a>
|
||||||
|
</li>
|
||||||
|
<li class="hidden-xs">
|
||||||
|
<a href="#node" data-toggle="tab">Node.js</a>
|
||||||
|
</li>
|
||||||
|
<li class="hidden-xs">
|
||||||
|
<a href="#php" data-toggle="tab">PHP</a>
|
||||||
|
</li>
|
||||||
|
<li class="hidden-xs">
|
||||||
|
<a href="#browser" data-toggle="tab">Browser</a>
|
||||||
|
</li>
|
||||||
|
<li class="hidden-xs">
|
||||||
|
<a href="#powershell" data-toggle="tab">PowerShell</a>
|
||||||
|
</li>
|
||||||
|
<li class="hidden-xs">
|
||||||
|
<a href="#email" data-toggle="tab">Email</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
|
||||||
|
|
||||||
|
<div class="tab-content">
|
||||||
|
{% with ping_url="<span class='ex'></span>" %}
|
||||||
|
<div role="tabpanel" class="tab-pane active" id="crontab">
|
||||||
|
{% include "front/snippets/crontab.html" %}
|
||||||
|
</div>
|
||||||
|
<div role="tabpanel" class="tab-pane" id="bash">
|
||||||
|
{% include "front/snippets/bash.html" %}
|
||||||
|
</div>
|
||||||
|
<div role="tabpanel" class="tab-pane" id="python">
|
||||||
|
{% include "front/snippets/python.html" %}
|
||||||
|
</div>
|
||||||
|
<div role="tabpanel" class="tab-pane" id="node">
|
||||||
|
{% include "front/snippets/node.html" %}
|
||||||
|
</div>
|
||||||
|
<div role="tabpanel" class="tab-pane" id="php">
|
||||||
|
{% include "front/snippets/php.html" %}
|
||||||
|
</div>
|
||||||
|
<div class="tab-pane" id="browser">
|
||||||
|
{% include "front/snippets/browser.html" %}
|
||||||
|
</div>
|
||||||
|
<div class="tab-pane" id="powershell">
|
||||||
|
{% include "front/snippets/powershell.html" %}
|
||||||
|
</div>
|
||||||
|
<div class="tab-pane" id="email">
|
||||||
|
As an alternative to HTTP/HTTPS requests,
|
||||||
|
you can "ping" this check by sending an
|
||||||
|
email message to
|
||||||
|
<div class="email-address">
|
||||||
|
<code class="em"></code>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{% endwith %}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
<button type="button" class="btn btn-default" data-dismiss="modal">Got It!</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
@ -4,10 +4,7 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<th></th>
|
<th></th>
|
||||||
<th class="th-name">Name</th>
|
<th class="th-name">Name</th>
|
||||||
<th>
|
<th>Ping URL</th>
|
||||||
<a id="show-urls" class="active" href="#">URL</a>
|
|
||||||
<a id="show-emails" href="#">Email</a>
|
|
||||||
</th>
|
|
||||||
<th class="th-period">
|
<th class="th-period">
|
||||||
Period <br />
|
Period <br />
|
||||||
<span class="checks-subline">Grace</span>
|
<span class="checks-subline">Grace</span>
|
||||||
@ -42,23 +39,14 @@
|
|||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td class="url-cell">
|
<td class="url-cell">
|
||||||
<div class="placeholder">{{ check.url }}</div>
|
<a
|
||||||
<div class="my-checks-url">
|
href="{{ check.url }}"
|
||||||
<input
|
class="my-checks-url"
|
||||||
data-toggle="tooltip"
|
title="Click to show usage examples"
|
||||||
title="Click to select"
|
data-email="{{ check.email }}"
|
||||||
class="selectable"
|
data-toggle="tooltip">
|
||||||
type="text"
|
{{ check.url }}
|
||||||
value="{{ check.url }}"
|
</a>
|
||||||
readonly />
|
|
||||||
</div>
|
|
||||||
<div class="my-checks-email off">
|
|
||||||
<input
|
|
||||||
class="selectable"
|
|
||||||
type="text"
|
|
||||||
value="{{ check.email }}"
|
|
||||||
readonly />
|
|
||||||
</div>
|
|
||||||
</td>
|
</td>
|
||||||
<td class="timeout-cell">
|
<td class="timeout-cell">
|
||||||
<span
|
<span
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
<div class="highlight"><pre><span></span><span class="c1"># using curl:</span>
|
<div class="highlight"><pre><span></span><span class="c1"># using curl:</span>
|
||||||
|
<span class="c1"># (make sure it is installed on your system!)</span>
|
||||||
curl --retry <span class="m">3</span> {{ ping_url }}
|
curl --retry <span class="m">3</span> {{ ping_url }}
|
||||||
|
|
||||||
<span class="c1"># using wget:</span>
|
<span class="c1"># using wget:</span>
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
# using curl:
|
# using curl:
|
||||||
|
# (make sure it is installed on your system!)
|
||||||
curl --retry 3 PING_URL
|
curl --retry 3 PING_URL
|
||||||
|
|
||||||
# using wget:
|
# using wget:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user