0

I try to create registration form and pass data for rest server for do registration, but I get this error only angular.js:11607 SyntaxError: Unexpected token o ...

controller:

$scope.signIn = function(){
    console.log($scope.ruser); // Object {username: "test@email.com",   password: "password"}
    $http.get('p/registration', $scope.ruser).success(function(data) {

    });
}

spring rest controller:

 @RequestMapping("/p/registration")
 public String user(com.app.objects.users.User user) {
    System.out.println(user.getUsername()+" "+user.getPassword()); //print: null null :{
    return "ok";
}
Edgaras Karka
  • 7,400
  • 15
  • 61
  • 115

0 Answers0