Merge branch 'develop' into loic
This commit is contained in:
commit
237b627bf6
8 changed files with 147 additions and 58 deletions
27
client/js/services/Network.js
Normal file
27
client/js/services/Network.js
Normal file
|
@ -0,0 +1,27 @@
|
|||
|
||||
mainApp.factory('Network',[ '$http', 'Identity', function($http, Identity){
|
||||
|
||||
var data={};
|
||||
data.networks=null;
|
||||
|
||||
var ListId=function(fileToUpload, callback) {
|
||||
|
||||
|
||||
var result=$http.post('../server/index.php',
|
||||
$.param({"token" : Identity.getToken(), "task" : "network", 'action':'list_network_ids'}));
|
||||
|
||||
// Wait and handle the response
|
||||
result.then(function (response){
|
||||
callback(parseUploadImageAnswer(response, false));
|
||||
},function(response){
|
||||
callback(parseUploadImageAnswer(response, true));
|
||||
});
|
||||
|
||||
console.log(result)
|
||||
|
||||
}
|
||||
|
||||
|
||||
}]);
|
||||
|
||||
|
8
client/js/services/Test.js
Normal file
8
client/js/services/Test.js
Normal file
|
@ -0,0 +1,8 @@
|
|||
var app = angular.module('mainApp',[]);
|
||||
app.controller('hassan', function($scope,$http){
|
||||
$http.get('http://127.0.0.1/database.json').success(function(response){
|
||||
$scope.persons = response.records;
|
||||
});
|
||||
|
||||
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue