-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #31 from Kernel360/feature/board-entity-update-#29
Feature/board entity update #29
- Loading branch information
Showing
8 changed files
with
62 additions
and
277 deletions.
There are no files selected for viewing
23 changes: 23 additions & 0 deletions
23
src/main/java/com/seveneleven/devlens/domain/board/dto/PostStatus.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.seveneleven.devlens.domain.board.dto; | ||
|
||
import lombok.Getter; | ||
|
||
@Getter | ||
public enum PostStatus { | ||
|
||
DEFAULT("선택"), | ||
IN_PROGRESS("진행"), | ||
ADDITION("추가"), | ||
COMPLETED("완료"), | ||
ON_HOLD("보류"); | ||
|
||
private final String description; | ||
|
||
PostStatus(String description) { | ||
this.description = description; | ||
} | ||
|
||
// 사용할지 고민 | ||
// FEEDBACK("피드백"), | ||
// REQUESTED("요청"); | ||
} |
34 changes: 0 additions & 34 deletions
34
src/main/java/com/seveneleven/devlens/domain/board/entity/Answer.java
This file was deleted.
Oops, something went wrong.
39 changes: 0 additions & 39 deletions
39
src/main/java/com/seveneleven/devlens/domain/board/entity/AnswerHistory.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
62 changes: 0 additions & 62 deletions
62
src/main/java/com/seveneleven/devlens/domain/board/entity/Question.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +0,0 @@ | ||
package com.seveneleven.devlens.domain.board.entity; | ||
|
||
import com.seveneleven.devlens.domain.member.entity.Member; | ||
import com.seveneleven.devlens.global.entity.BaseEntity; | ||
import jakarta.persistence.*; | ||
import lombok.*; | ||
import org.springframework.data.annotation.CreatedBy; | ||
import org.springframework.data.annotation.CreatedDate; | ||
import org.springframework.data.annotation.LastModifiedBy; | ||
import org.springframework.data.annotation.LastModifiedDate; | ||
|
||
import java.time.LocalDateTime; | ||
|
||
@Entity | ||
@Getter | ||
@Setter | ||
@ToString | ||
@Builder(toBuilder = true) | ||
@NoArgsConstructor | ||
@AllArgsConstructor(access = AccessLevel.PRIVATE) | ||
@Table(name = "question") | ||
public class Question extends BaseEntity { | ||
|
||
@Id | ||
@GeneratedValue(strategy = GenerationType.IDENTITY) | ||
@Column(name = "question_id") | ||
private Long questionId; // 질문 ID | ||
|
||
@JoinColumn(name = "post_id", nullable = false) | ||
@OneToOne(fetch = FetchType.LAZY) | ||
private Post postId; // 게시물 ID | ||
|
||
@Column(name = "question_content", nullable = false, columnDefinition = "TEXT") | ||
private String questionContent; // 질문 내용 | ||
|
||
@Column(name = "answer_content", columnDefinition = "TEXT") | ||
private String answerContent; // 답변 내용 | ||
|
||
@CreatedDate | ||
@Column(name = "registered_date", nullable = false, updatable = false) | ||
private LocalDateTime registeredDate; // 등록일시 | ||
|
||
@LastModifiedDate | ||
@Column(name = "modification_date") | ||
private LocalDateTime modificationDate; // 수정일시 | ||
|
||
@CreatedBy | ||
@JoinColumn(name = "register_id", updatable = false, referencedColumnName = "id") | ||
@OneToOne(fetch = FetchType.LAZY) | ||
private Member registerId; // 등록자 | ||
|
||
@LastModifiedBy | ||
@JoinColumn(name = "modified_id", referencedColumnName = "id") | ||
@OneToOne(fetch = FetchType.LAZY) | ||
private Member modifierId; // 수정자 | ||
|
||
@Column(name = "register_ip", length = 50) | ||
private String registerIp; // 등록자 IP | ||
|
||
@Column(name = "modifier_ip", length = 50) | ||
private String modifierIp; // 수정자 IP | ||
} | ||
Oops, something went wrong.