Open luanne opened 9 years ago
I have an error in the same area
[ratpack-compute-1-6] ERROR ratpack.error.internal.DefaultDevelopmentErrorHandler - exception thrown for request to /api/students com.fasterxml.jackson.databind.JsonMappingException: Can not instantiate value of type [simple type, class school.domain.Enrollment] from Integral number (740); no single-int-arg constructor/factory method at [Source: io.netty.buffer.ByteBufInputStream@51342177; line: 1, column: 17] (through reference chain: school.domain.Student["enrollments"]->java.util.HashSet[0])
It seems that only the id of the class (740) is passed to the Enrollment creator, whereas it would need also the student Id. I cannot find where I should specify that as RelationshipEntity, the constructor should receive both ends. Any idea if this is the same problem that you report? Thanks, hj
Enrolling any student other than the first for a class does not work. Angular code to be updated to manage enrollments.