You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

17 lines
504 B

app.controller('ListUsersController', function($scope, $http, $cookieStore) {
if(typeof($cookieStore.get('user')) != "undefined"){
$scope.user = $cookieStore.get('user');
}
$http({
method: 'GET',
url: serverURL+"/user/list",
data: {
user: $scope.user
},
headers: {'Content-Type': 'application/x-www-form-urlencoded'},
}).success(function(data, status, headers, config) {
$scope.list = data.users;
}).error(function(data, status, headers, config) {
console.log("error");
});
});