apiServices: Added GetUserById & get GetCampusByUserId

This commit is contained in:
Sagi Dayan 2015-06-26 15:06:59 +03:00
parent 0e37e51b4d
commit 43de4f9b80

View file

@ -123,8 +123,26 @@ service.factory('apiService', ['$http', function($http) {
method : "GET",
url : url
};
return $http(req);
},
getUserById: function(token, id){
var url = (DEBUG ? "http://localhost:8080" : "http://se-hub.appspot.com") + "/api/users/getUserById/" + token + "/" + id;
req = {
method : "GET",
url : url
};
return $http(req);
},
getCampusesByUserId: function(token, id){
var url = (DEBUG ? "http://localhost:8080" : "http://se-hub.appspot.com") + "/api/campuses/getCampusesByUserID/" + token + "/" + id;
req = {
method : "GET",
url : url
};
return $http(req);
}
};
}]);