admin: fix some details about times

This commit is contained in:
nemunaire 2018-01-23 03:59:38 +01:00
parent 45620ba4c2
commit 167a6ae1cb
1 changed files with 2 additions and 4 deletions

View File

@ -1257,9 +1257,6 @@ angular.module("FICApp")
var time = angular.fromJson(sessionStorage.userService);
var srv_cur = (Date.now() + (time.cu * 1000 - time.he)) / 1000;
var remain = time.du;
if (time.st == Math.floor(srv_cur)) {
$scope.refresh(true);
}
if (time.st > 0 && time.st <= srv_cur) {
$scope.startIn = 0;
remain = time.st + time.du - srv_cur;
@ -1287,7 +1284,8 @@ angular.module("FICApp")
}
}
$http.get("/time.json").then(function(time) {
$http.get("/time.json").then(function(response) {
var time = response.data;
time.he = (new Date()).getTime();
sessionStorage.userService = angular.toJson(time);
updTime();