Skip to content
Snippets Groups Projects
Commit c227db21 authored by Erik Reid's avatar Erik Reid
Browse files

decouple check status and update timers

parent 72400d3f
Branches
Tags
No related merge requests found
......@@ -30,9 +30,6 @@ myApp.controller('update', function($scope, $http, $timeout) {
$scope.update_request_status = "";
}
$timeout($scope.check_status, 5000);
if ($scope.latch_pending || $scope.latch_error) {
$scope.refresh_update_status();
}
},
/* error response */
function(rsp) {
......@@ -58,6 +55,7 @@ myApp.controller('update', function($scope, $http, $timeout) {
$scope.failed = rsp.data.failed;
$scope.warnings = rsp.data.warnings;
$scope.errors = rsp.data.errors;
$timeout($scope.refresh_update_status, 2000);
},
/* error response */
function(rsp) {
......@@ -66,6 +64,7 @@ myApp.controller('update', function($scope, $http, $timeout) {
$scope.failed = [];
$scope.errors = [];
$scope.warnings = [];
$timeout($scope.refresh_update_status, 5000);
}
);
......@@ -95,4 +94,6 @@ myApp.controller('update', function($scope, $http, $timeout) {
}
$scope.check_status();
$scope.refresh_update_status();
});
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment