2015-02-08 22:27:58 +00:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html lang="en">
|
|
|
|
<head>
|
2019-03-24 19:57:21 +00:00
|
|
|
<link rel="stylesheet" href="http://netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" />
|
2015-02-08 22:27:58 +00:00
|
|
|
<link href='http://fonts.googleapis.com/css?family=Sintony:700' rel='stylesheet' type='text/css'>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
|
2019-03-24 19:57:21 +00:00
|
|
|
<style>
|
|
|
|
.alerta-div {width:100%; padding:20px;}
|
|
|
|
.alerta-table {width:100%; border:1px solid lightgrey; text-align:center;}
|
|
|
|
</style>
|
|
|
|
|
2015-02-08 22:27:58 +00:00
|
|
|
<div class="mobile-alerts">Loading...</div>
|
|
|
|
|
2019-03-24 19:57:21 +00:00
|
|
|
<script src="http://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
|
|
|
|
<script src="http://netdna.bootstrapcdn.com/bootstrap/3.3.2/js/bootstrap.min.js"></script>
|
|
|
|
|
|
|
|
<!-- Use http://localhost:8080/api/embed.js if you run docker image with alerta. -->
|
|
|
|
<script src="http://localhost:8080/embed.js"></script>
|
|
|
|
|
2015-02-08 22:27:58 +00:00
|
|
|
<script>
|
2019-03-24 19:57:21 +00:00
|
|
|
$(window).on('load', function () {
|
2015-02-08 22:27:58 +00:00
|
|
|
|
2019-03-24 19:57:21 +00:00
|
|
|
// Use http://localhost:8080/api as endpoint, if you run docker image with alerta.
|
|
|
|
//
|
2015-02-08 22:27:58 +00:00
|
|
|
// $.alerta.defaults.endpoint = 'http://localhost:8080';
|
|
|
|
// $.alerta.defaults.key = 'demo-key';
|
|
|
|
// or
|
|
|
|
$.alerta.defaults = {
|
2019-03-24 19:57:21 +00:00
|
|
|
endpoint: 'http://localhost:8080', // oEmbed endpoint becomes http://localhost:8080/oembed
|
2015-02-08 22:27:58 +00:00
|
|
|
key: 'demo-key'
|
|
|
|
};
|
|
|
|
|
2019-03-24 19:57:21 +00:00
|
|
|
function renew() {
|
|
|
|
$('.mobile-alerts').alerta('http://localhost:8080/alerts/count?service=Mobile&status=open', {title:'Mobile Service'});
|
|
|
|
|
|
|
|
setTimeout(renew, 30000);
|
|
|
|
}
|
2015-02-08 22:27:58 +00:00
|
|
|
|
2019-03-24 19:57:21 +00:00
|
|
|
renew();
|
2015-02-08 22:27:58 +00:00
|
|
|
});
|
|
|
|
</script>
|
|
|
|
</body>
|
|
|
|
</html>
|