diff --git a/src/main/java/com/smunity/server/global/common/entity/Member.java b/src/main/java/com/smunity/server/global/common/entity/Member.java index b100680..29be7e7 100644 --- a/src/main/java/com/smunity/server/global/common/entity/Member.java +++ b/src/main/java/com/smunity/server/global/common/entity/Member.java @@ -1,5 +1,6 @@ package com.smunity.server.global.common.entity; +import com.smunity.server.domain.account.entity.LoginStatus; import com.smunity.server.domain.answer.entity.Answer; import com.smunity.server.domain.course.entity.Course; import com.smunity.server.domain.question.entity.Question; @@ -60,6 +61,9 @@ public class Member extends BaseEntity { @OneToMany(mappedBy = "member", cascade = CascadeType.ALL, orphanRemoval = true) private final List answers = new ArrayList<>(); + @OneToMany(mappedBy = "member", cascade = CascadeType.ALL, orphanRemoval = true) + private final List loginStatuses = new ArrayList<>(); + public void setDepartment(Department department) { this.department = department; department.getMembers().add(this);