diff --git a/src/main/java/com/recipe/app/src/recipe/application/dto/RecipeDetailResponse.java b/src/main/java/com/recipe/app/src/recipe/application/dto/RecipeDetailResponse.java index 37a71dd0..3bcfc947 100644 --- a/src/main/java/com/recipe/app/src/recipe/application/dto/RecipeDetailResponse.java +++ b/src/main/java/com/recipe/app/src/recipe/application/dto/RecipeDetailResponse.java @@ -39,13 +39,18 @@ public class RecipeDetailResponse { private final Long postUserId; @Schema(description = "게시자명") private final String postUserName; + @Schema(description = "게시자 프로필 이미지") + private final String postUserProfileImage; @Schema(description = "신고 여부") private final Boolean isReported; + @Schema(description = "공개 여부") + private final Boolean isHidden; @Builder public RecipeDetailResponse(Long recipeId, String recipeName, String introduction, String thumbnailImgUrl, Long cookingTime, String level, List recipeIngredients, List recipeProcesses, - Boolean isUserScrap, long scrapCnt, long viewCnt, Long postUserId, String postUserName, Boolean isReported) { + Boolean isUserScrap, long scrapCnt, long viewCnt, Long postUserId, String postUserName, String postUserProfileImage, + Boolean isReported, Boolean isHidden) { this.recipeId = recipeId; this.recipeName = recipeName; @@ -60,7 +65,9 @@ public RecipeDetailResponse(Long recipeId, String recipeName, String introductio this.viewCnt = viewCnt; this.postUserId = postUserId; this.postUserName = postUserName; + this.postUserProfileImage = postUserProfileImage; this.isReported = isReported; + this.isHidden = isHidden; } public static RecipeDetailResponse from(Recipe recipe, boolean isUserScrap, User postUser, List ingredientNamesInFridge) { @@ -85,7 +92,9 @@ public static RecipeDetailResponse from(Recipe recipe, boolean isUserScrap, User .viewCnt(recipe.getViewCnt()) .postUserId(postUser != null ? postUser.getUserId() : null) .postUserName(postUser != null ? postUser.getNickname() : null) + .postUserProfileImage(postUser != null ? postUser.getProfileImgUrl() : null) .isReported(recipe.isReported()) + .isHidden(recipe.isHidden()) .build(); } } \ No newline at end of file