diff options
Diffstat (limited to 'client/js/services/Compute.js')
| -rw-r--r-- | client/js/services/Compute.js | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/client/js/services/Compute.js b/client/js/services/Compute.js new file mode 100644 index 0000000..c5c8da9 --- /dev/null +++ b/client/js/services/Compute.js @@ -0,0 +1,40 @@ + +mainApp.factory('Compute',[ '$http', 'Identity', function($http, Identity){ + + + + var data={}; + data.machines={}; + + + // Parser + var parseGetMachinesAnswer=function(response, failedToSendRequest){ + + }; + + + // Get Machine + var getMachines=function(callback){ + + var result=$http.post('../server/index.php', + $.param({"token" : Identity.profile.token, "task" : "Compute"})); + + + }; + + + + var pullData=function(callback){ + // TODO call getMachines etc... + } + + + // Return services objects + return { + getMachines: getMachines + pullData: pullData + data:data + }; + + +}]); |
