From 0508deae748fa29535d49e1854321fb12924912e Mon Sep 17 00:00:00 2001 From: epdlrnldudnj Date: Mon, 22 Jan 2024 19:26:59 +0900 Subject: [PATCH] =?UTF-8?q?calender=20=EC=BB=A8=ED=8A=B8=EB=A1=A4=EB=9F=AC?= =?UTF-8?q?=20=EC=9E=91=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 서비스는 1도 작성 안함. 농사 - localdatetime 타입 공부 필요 자세히 보기 - 게시글 모음 구현 힘들것같아서 미룸 --- .../controller/calendarController.java | 32 +++++++++++++++++-- .../profile/service/CalendarService.java | 2 ++ .../kimgreen/backend/response/Message.java | 2 ++ 3 files changed, 34 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/kimgreen/backend/domain/profile/controller/calendarController.java b/src/main/java/com/kimgreen/backend/domain/profile/controller/calendarController.java index 4ea8d7a..ba05c8f 100644 --- a/src/main/java/com/kimgreen/backend/domain/profile/controller/calendarController.java +++ b/src/main/java/com/kimgreen/backend/domain/profile/controller/calendarController.java @@ -1,12 +1,40 @@ package com.kimgreen.backend.domain.profile.controller; +import com.kimgreen.backend.domain.member.dto.Auth.SignUpRequestDto; +import com.kimgreen.backend.domain.profile.service.CalendarService; +import com.kimgreen.backend.response.Response; +import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.tags.Tag; +import lombok.AllArgsConstructor; import org.springframework.stereotype.Controller; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.*; + +import java.time.LocalDateTime; + +import static com.kimgreen.backend.response.Message.*; +import static com.kimgreen.backend.response.Response.success; +import static org.springframework.http.HttpStatus.OK; @Tag(name = "Calendar") @RestController @RequestMapping(value="/calendar") +@AllArgsConstructor public class calendarController { + + private final CalendarService calendarService; + @Operation(summary = "프로필 달력 불러오기 (농사 잘했는지 불러오는거)") + @ResponseStatus(OK) + @GetMapping("/calender") + public Response getCalender(@RequestParam("memberId") Long memberId, @RequestParam("date")LocalDateTime localDateTime) { + + return success(CALENDAR_SUCCESS); + } + + @Operation(summary = "프로필 달력 상세정보 불러오기 (글들 불러오는거임)") + @ResponseStatus(OK) + @GetMapping("/calender-details") + public Response getCalenderDetails(@RequestBody SignUpRequestDto signUpRequestDto) { + + return success(CALENDAR_DETAILS_SUCCESS); + } } diff --git a/src/main/java/com/kimgreen/backend/domain/profile/service/CalendarService.java b/src/main/java/com/kimgreen/backend/domain/profile/service/CalendarService.java index 9d1dc34..8c24412 100644 --- a/src/main/java/com/kimgreen/backend/domain/profile/service/CalendarService.java +++ b/src/main/java/com/kimgreen/backend/domain/profile/service/CalendarService.java @@ -1,7 +1,9 @@ package com.kimgreen.backend.domain.profile.service; +import lombok.AllArgsConstructor; import org.springframework.stereotype.Service; @Service +@AllArgsConstructor public class CalendarService { } diff --git a/src/main/java/com/kimgreen/backend/response/Message.java b/src/main/java/com/kimgreen/backend/response/Message.java index ac65826..c4491a0 100644 --- a/src/main/java/com/kimgreen/backend/response/Message.java +++ b/src/main/java/com/kimgreen/backend/response/Message.java @@ -17,5 +17,7 @@ public class Message { public static String GET_NOT_COLLECTED_BADGE_INFO="미획득 뱃지 상세정보 불러오기 성공했습니다."; public static String SUCCESS_GET_NOTIFICATION ="푸시알림 내역 보기 성공했습니다."; public static String POST_REPORT_SUCCESS="게시글 신고하기 성공했습니다."; + public static String CALENDAR_SUCCESS="프로필 달력 불러오기 성공했습니다."; + public static String CALENDAR_DETAILS_SUCCESS="프로필 달력 상세정보 불러오기 성공했습니다."; }