diff --git a/backend/src/main/java/ovh/herisson/Clyde/Tables/Msg/AppointmentStatus.java b/backend/src/main/java/ovh/herisson/Clyde/Tables/Msg/AppointmentStatus.java new file mode 100644 index 0000000..a3a03cf --- /dev/null +++ b/backend/src/main/java/ovh/herisson/Clyde/Tables/Msg/AppointmentStatus.java @@ -0,0 +1,9 @@ +package ovh.herisson.Clyde.Tables.Msg; + +public enum AppointmentStatus { + WAITING_TEACHER, + WAITING_STUDENT, + CONFIRMED, + REFUSED +} + diff --git a/backend/src/main/java/ovh/herisson/Clyde/Tables/Msg/Appointments.java b/backend/src/main/java/ovh/herisson/Clyde/Tables/Msg/Appointments.java new file mode 100644 index 0000000..68f1ce3 --- /dev/null +++ b/backend/src/main/java/ovh/herisson/Clyde/Tables/Msg/Appointments.java @@ -0,0 +1,30 @@ +package ovh.herisson.Clyde.Tables.Msg; + + +import java.util.Date; + +import jakarta.persistence.Entity; +import jakarta.persistence.EnumType; +import jakarta.persistence.Enumerated; +import jakarta.persistence.GeneratedValue; +import jakarta.persistence.GenerationType; +import jakarta.persistence.Id; +import jakarta.persistence.ManyToOne; +import ovh.herisson.Clyde.Tables.User; + +@Entity +public class Appointments { + + @Id + @GeneratedValue(strategy = GenerationType.AUTO) + private int id; + + @ManyToOne + private User teacher, student; + + private Date planned; + + @Enumerated(EnumType.STRING) + private AppointmentStatus status; + +}