diff --git a/src/main/java/com/example/helloworldmvc/converter/CommunityConverter.java b/src/main/java/com/example/helloworldmvc/converter/CommunityConverter.java index 028ac79..ae955fb 100644 --- a/src/main/java/com/example/helloworldmvc/converter/CommunityConverter.java +++ b/src/main/java/com/example/helloworldmvc/converter/CommunityConverter.java @@ -68,6 +68,7 @@ public static CommunityResponseDTO.PostDetailDTO toPostDetailDTO(Community commu return CommunityResponseDTO.PostDetailDTO.builder() .title(community.getTitle()) .content(community.getContent()) + .category_id(toCategoryId(community.getCommunityCategory())) .created_at(community.getCreatedAt()) .isOwner(isOwner) .fileList(list) diff --git a/src/main/java/com/example/helloworldmvc/web/dto/CommunityResponseDTO.java b/src/main/java/com/example/helloworldmvc/web/dto/CommunityResponseDTO.java index 6363f76..2124f8c 100644 --- a/src/main/java/com/example/helloworldmvc/web/dto/CommunityResponseDTO.java +++ b/src/main/java/com/example/helloworldmvc/web/dto/CommunityResponseDTO.java @@ -46,6 +46,7 @@ public static class PostDTO{ public static class PostDetailDTO{ String title; String content; + Long category_id; LocalDateTime created_at; List fileList; List commentDTOList;