Clyde/backend/src/main/java/ovh/herisson/Clyde/Tables/UserCurriculum.java
Bartha Maxime e2da7271af
All checks were successful
Build and test backend / Build-backend (pull_request) Successful in 2m3s
Build and test backend / Test-backend (pull_request) Successful in 2m0s
Build and test FrontEnd / Build-frontend (pull_request) Successful in 23s
rename Cursus -> Curriculum
2024-03-15 23:53:15 +01:00

47 lines
962 B
Java

package ovh.herisson.Clyde.Tables;
import jakarta.persistence.*;
@Entity
public class UserCurriculum {
@Id
@GeneratedValue(strategy = GenerationType.AUTO)
private int id;
//Un étudiant peut avoir plusieurs curriculums
@ManyToOne(fetch = FetchType.EAGER)
@JoinColumn(name = "Users")
private User user;
@OneToOne(fetch = FetchType.EAGER)
@JoinColumn(name = "Curriculum")
private Curriculum curriculum;
public UserCurriculum(User user, Curriculum curriculum){
this.user = user;
this.curriculum = curriculum;
}
public UserCurriculum() {}
public int getId() {
return id;
}
public User getUser() {
return user;
}
public void setUser(User user) {
this.user = user;
}
public Curriculum getCurriculum() {
return curriculum;
}
public void setCurriculum(Curriculum curriculum) {
this.curriculum = curriculum;
}
}