diff --git a/backend/src/main/java/com/edufocus/edufocus/registration/entity/Registration.java b/backend/src/main/java/com/edufocus/edufocus/registration/entity/Registration.java index c5d302a..1d2870d 100644 --- a/backend/src/main/java/com/edufocus/edufocus/registration/entity/Registration.java +++ b/backend/src/main/java/com/edufocus/edufocus/registration/entity/Registration.java @@ -22,11 +22,11 @@ public class Registration { @GeneratedValue(strategy = GenerationType.IDENTITY) private long id; - @ManyToOne + @ManyToOne(cascade = CascadeType.ALL) @JoinColumn(name = "user_id") private User user; - @ManyToOne + @ManyToOne(cascade = CascadeType.ALL) @JoinColumn(name = "lecture_id") private Lecture lecture;