Add sharedProfile service
This commit is contained in:
parent
a16df328c0
commit
cca5df968e
8 changed files with 42 additions and 33 deletions
|
@ -4,25 +4,11 @@
|
|||
|
||||
|
||||
|
||||
mainApp.controller('statusCtrl', function ($scope,$interval,$sce)
|
||||
|
||||
|
||||
mainApp.controller('statusCtrl', ['$scope','sharedProfile', function ($scope, sharedProfile)
|
||||
{
|
||||
$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);*/
|
||||
|
||||
|
||||
|
||||
$scope.profile=sharedProfile;
|
||||
|
||||
|
||||
|
||||
});
|
||||
}]);
|
Loading…
Add table
Add a link
Reference in a new issue