feat: add employee fields (birthDate, education, residence) + emergency contacts
This commit is contained in:
@@ -10,6 +10,7 @@ import org.hibernate.annotations.SQLDelete;
|
||||
import org.hibernate.annotations.SQLRestriction;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.List;
|
||||
|
||||
@Entity
|
||||
@Table(name = "tb_employee")
|
||||
@@ -60,4 +61,23 @@ public class Employee extends BaseEntity {
|
||||
|
||||
@Column(name = "left_date")
|
||||
private LocalDate leftDate;
|
||||
|
||||
@Column(name = "birth_date")
|
||||
private LocalDate birthDate;
|
||||
|
||||
@Column(name = "education", length = 20)
|
||||
private String education;
|
||||
|
||||
@Column(name = "major", length = 100)
|
||||
private String major;
|
||||
|
||||
@Column(name = "graduation_date")
|
||||
private LocalDate graduationDate;
|
||||
|
||||
@Column(name = "residence", length = 255)
|
||||
private String residence;
|
||||
|
||||
@OneToMany(mappedBy = "employee", cascade = CascadeType.ALL, orphanRemoval = true)
|
||||
@OrderBy("sortOrder ASC")
|
||||
private List<EmployeeEmergencyContact> emergencyContacts;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user