Skip to content

Commit

Permalink
BE: [feat] 미리보기 postId 반환 CSID-DGU#36
Browse files Browse the repository at this point in the history
  • Loading branch information
Seoyoung2222 committed Nov 25, 2024
1 parent dfb89c5 commit ee7cd68
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@AllArgsConstructor
@Builder
public class PostShowSimpleResponseDto {
private Long postId;
private String title;
private String writer;
private LocalDateTime createdAt;
Expand All @@ -24,6 +25,7 @@ public class PostShowSimpleResponseDto {

public static PostShowSimpleResponseDto fromPost(Post post) {
return PostShowSimpleResponseDto.builder()
.postId(post.getId())
.title(post.getTitle())
.writer(post.getUser().getNickname())
.createdAt(post.getCreatedAt())
Expand Down

0 comments on commit ee7cd68

Please sign in to comment.