Adding appointment table
This commit is contained in:
		| @ -0,0 +1,9 @@ | |||||||
|  | package ovh.herisson.Clyde.Tables.Msg; | ||||||
|  |  | ||||||
|  | public enum AppointmentStatus { | ||||||
|  | 	WAITING_TEACHER, | ||||||
|  | 	WAITING_STUDENT, | ||||||
|  | 	CONFIRMED, | ||||||
|  | 	REFUSED | ||||||
|  | } | ||||||
|  |  | ||||||
| @ -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; | ||||||
|  |  | ||||||
|  | } | ||||||
		Reference in New Issue
	
	Block a user