Skip to content

Commit

Permalink
[fix] #71 post 조회시 title, content 데이터 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
RyuKwanKon committed Apr 1, 2024
1 parent 83c1195 commit 0dc255c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
@Builder
public record PostDetailResponseDto(
Long memberId,
String title,
String content,
String name,
String major,
String profile,
Expand All @@ -20,6 +22,8 @@ public record PostDetailResponseDto(
public static PostDetailResponseDto of(PostDetailDto postDetailDto, CheckListResponseDto checkList, boolean isScrap) {
return PostDetailResponseDto.builder()
.memberId(postDetailDto.memberId())
.title(postDetailDto.title())
.content(postDetailDto.content())
.name(postDetailDto.name())
.major(postDetailDto.major())
.profile(postDetailDto.profile())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

public record PostDetailDto(
Long memberId,
String title,
String content,
String major,
MbtiType mbti,
GenderType gender,
Expand All @@ -20,8 +22,10 @@ public record PostDetailDto(
PostCheckList postCheckList
) {
@QueryProjection
public PostDetailDto(Long memberId, String major, MbtiType mbti, GenderType gender, RoomType roomType, DormitoryType dormitoryType, String name, String profile, PostCheckList postCheckList) {
public PostDetailDto(Long memberId, String title, String content, String major, MbtiType mbti, GenderType gender, RoomType roomType, DormitoryType dormitoryType, String name, String profile, PostCheckList postCheckList) {
this.memberId = memberId;
this.title = title;
this.content = content;
this.major = major;
this.mbti = mbti;
this.gender = gender;
Expand Down

0 comments on commit 0dc255c

Please sign in to comment.