blob: 64615024ff74c3b537740f251a9a1c0ad41a5c8f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
var statusapp = angular.module('status-app', []);
var UPDATE_INTERVAL = 60000;
statusapp.controller('status-controller', ['$scope', '$http', function status_controller($scope, $http) {
$scope.systems = [];
var update = function() {
$http({
method: "GET",
url: "/status"
}).then(function successCallback(response) {
$scope.systems = response.data;
}, function errorCallback(response) {
});
};
setInterval(update, UPDATE_INTERVAL);
update();
}]);
|