Skip to content

Instantly share code, notes, and snippets.

@tristanpendergrass
Created November 26, 2014 18:09
Show Gist options
  • Save tristanpendergrass/9a9940cc5644675c6cc6 to your computer and use it in GitHub Desktop.
Save tristanpendergrass/9a9940cc5644675c6cc6 to your computer and use it in GitHub Desktop.
Console.getMonitors().then(function(results) {
$scope.monitors = results.data.monitors;
angular.forEach(results['data']['monitors'], function(value, key) {
var id = value.Monitor.Id;
Console.daemonStatus(id, 'zmc').then(function(results) {
$scope[id] = {
zmc: results.data.status
};
});
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment