diff --git a/src/main/java/ddingdong/ddingdongBE/domain/activityreport/api/AdminActivityReportApi.java b/src/main/java/ddingdong/ddingdongBE/domain/activityreport/api/AdminActivityReportApi.java index 4dbc4a48..af43fa67 100644 --- a/src/main/java/ddingdong/ddingdongBE/domain/activityreport/api/AdminActivityReportApi.java +++ b/src/main/java/ddingdong/ddingdongBE/domain/activityreport/api/AdminActivityReportApi.java @@ -1,6 +1,5 @@ package ddingdong.ddingdongBE.domain.activityreport.api; -import ddingdong.ddingdongBE.auth.PrincipalDetails; import ddingdong.ddingdongBE.domain.activityreport.controller.dto.request.CreateActivityTermInfoRequest; import ddingdong.ddingdongBE.domain.activityreport.controller.dto.response.ActivityReportTermInfoResponse; import ddingdong.ddingdongBE.domain.activityreport.controller.dto.response.AllActivityReportResponse; @@ -9,7 +8,6 @@ import io.swagger.v3.oas.annotations.tags.Tag; import java.util.List; import org.springframework.http.HttpStatus; -import org.springframework.security.core.annotation.AuthenticationPrincipal; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; @@ -29,16 +27,12 @@ public interface AdminActivityReportApi { @GetMapping("/term") @ResponseStatus(HttpStatus.OK) @SecurityRequirement(name = "AccessToken") - List getActivityTermInfos( - @AuthenticationPrincipal PrincipalDetails principalDetails); + List getActivityTermInfos(); @Operation(summary = "활동 보고서 회차별 기간 설정 API") @PostMapping("/term") @ResponseStatus(HttpStatus.CREATED) @SecurityRequirement(name = "AccessToken") - void createActivityTermInfo( - @AuthenticationPrincipal PrincipalDetails principalDetails, - @RequestBody CreateActivityTermInfoRequest request - ); + void createActivityTermInfo(@RequestBody CreateActivityTermInfoRequest request); } diff --git a/src/main/java/ddingdong/ddingdongBE/domain/activityreport/controller/AdminActivityReportApiController.java b/src/main/java/ddingdong/ddingdongBE/domain/activityreport/controller/AdminActivityReportApiController.java index e242948f..30af3356 100644 --- a/src/main/java/ddingdong/ddingdongBE/domain/activityreport/controller/AdminActivityReportApiController.java +++ b/src/main/java/ddingdong/ddingdongBE/domain/activityreport/controller/AdminActivityReportApiController.java @@ -1,6 +1,5 @@ package ddingdong.ddingdongBE.domain.activityreport.controller; -import ddingdong.ddingdongBE.auth.PrincipalDetails; import ddingdong.ddingdongBE.domain.activityreport.api.AdminActivityReportApi; import ddingdong.ddingdongBE.domain.activityreport.controller.dto.request.CreateActivityTermInfoRequest; import ddingdong.ddingdongBE.domain.activityreport.controller.dto.response.ActivityReportTermInfoResponse; @@ -9,7 +8,6 @@ import ddingdong.ddingdongBE.domain.activityreport.service.ActivityReportTermInfoService; import java.util.List; import lombok.RequiredArgsConstructor; -import org.springframework.security.core.annotation.AuthenticationPrincipal; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; @@ -26,16 +24,12 @@ public List getActivityReports() { } @Override - public List getActivityTermInfos( - @AuthenticationPrincipal PrincipalDetails principalDetails) { + public List getActivityTermInfos() { return activityReportTermInfoService.getAll(); } @Override - public void createActivityTermInfo( - @AuthenticationPrincipal PrincipalDetails principalDetails, - CreateActivityTermInfoRequest request - ) { + public void createActivityTermInfo(CreateActivityTermInfoRequest request) { activityReportTermInfoService.create(request.startDate(), request.totalTermCount()); }