Finish details machine
This commit is contained in:
parent
5ef1c9b8b1
commit
e9108d4b97
4 changed files with 69 additions and 26 deletions
|
@ -6,19 +6,19 @@
|
|||
mainApp.controller('homeCtrl', [ '$scope', 'Compute', '$rootScope', function ($scope, Compute, $rootScope)
|
||||
{
|
||||
|
||||
var callMeAfterGetMachines=function(data){
|
||||
var callMeAfterPullData=function(data){
|
||||
$scope.machines=Compute.getData().machines;
|
||||
}
|
||||
|
||||
|
||||
Compute.pullMachines(callMeAfterGetMachines);
|
||||
Compute.pullData(callMeAfterPullData);
|
||||
|
||||
|
||||
|
||||
$scope.raiseShowMachineDetailsEvent=function(id){
|
||||
var callback=function(){
|
||||
var data=Compute.getData();
|
||||
$rootScope.$broadcast("showMachineDetailsEvent", data.machines[id]);
|
||||
$rootScope.$broadcast("showMachineDetailsEvent", data.machines[id], data.axioms);
|
||||
|
||||
}
|
||||
Compute.pullMachines(callback);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue