Hello, 

I am using angularJs with jersey. 

On the server side I return object Patient

    @GET
    @Path("/patient/empty")
    @Produces(MediaType.APPLICATION_JSON)

    public Patient getEmptyUser() {
        Patient patient = new Patient();

        patient.setPatientId(135);
        patient.setEmail("test");
        patient.setPassword("pspspspsp");
        return patient;

    }



but on the client side I see

{ "patientId": 135, "password": "pspspspsp", "email": "test", "route": 
"rest/login/patient/empty", "parentResource": null, "restangularCollection": 
false }

So when I try to send this object back to the server I cannot convert it to 
Patient


    @POST
    @Path("/patient")
    @Produces(MediaType.APPLICATION_JSON)
    public Patient getPatient(Patient patient) {
         ....
    }


And actually I do not receive object Patient in the getPatient method, I 
receive LinkedHashMap.

What is the problem? 
Please advice. 


Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to