diff options
Diffstat (limited to 'client/js/controllers/status.js')
| -rw-r--r-- | client/js/controllers/status.js | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/client/js/controllers/status.js b/client/js/controllers/status.js index 3534912..42a54d4 100644 --- a/client/js/controllers/status.js +++ b/client/js/controllers/status.js @@ -4,9 +4,25 @@ -mainApp.controller('statusCtrl', function ($scope) +mainApp.controller('statusCtrl', function ($scope,$interval,$sce) { - $scope.username="User 1"; - $scope.connection="Online"; - $scope.lastconnection="1 Septembre"; + $scope.username="John Doe"; + $scope.projectname="Web Server"; + // Update status every 2 seconds + /*$interval(function(){ + var status=identity.fetchStatus(); + $scope.username=status[1]; + $scope.lastconnection=status[2]; + if(status[0] == "1"){ + $scope.connection=$sce.trustAsHtml("<span style=\"color:green;\">Online</span>"); + } + else{ + $scope.connection=$sce.trustAsHtml("<span style=\"color:red;\">Offline</span>"); + } + }, 2000);*/ + + + + + });
\ No newline at end of file |
