이미지 단일조회 추가

This commit is contained in:
DanielLee
2026-01-15 14:19:20 +09:00
parent 94077377f2
commit 6f14dbfc0f
6 changed files with 90 additions and 62 deletions

View File

@@ -465,7 +465,7 @@ public class TrainingDataReviewApiController {
return ApiResponseDto.okObject(trainingDataReviewService.saveNewPolygon(request));
}
@Operation(summary = "COG 이미지 URL 조회", description = "변화 전/후 COG 이미지 URL을 함께 조회합니다")
@Operation(summary = "COG 이미지 URL 조회", description = "변화 전/후 COG 이미지 URL을 조회합니다. beforeYear와 afterYear 중 최소 하나는 필수입니다.")
@ApiResponses(
value = {
@ApiResponse(
@@ -476,6 +476,7 @@ public class TrainingDataReviewApiController {
mediaType = "application/json",
schema =
@Schema(implementation = TrainingDataReviewDto.CogImageResponse.class))),
@ApiResponse(responseCode = "400", description = "년도 파라미터가 하나도 제공되지 않음", content = @Content),
@ApiResponse(responseCode = "404", description = "이미지를 찾을 수 없음", content = @Content),
@ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
})
@@ -483,9 +484,9 @@ public class TrainingDataReviewApiController {
public ApiResponseDto<TrainingDataReviewDto.CogImageResponse> getCogImageUrl(
@Parameter(description = "도엽번호", required = true, example = "35905086") @RequestParam
String mapSheetNum,
@Parameter(description = "변화 전 년도", required = true, example = "2023") @RequestParam
@Parameter(description = "변화 전 년도", required = false, example = "2023") @RequestParam(required = false)
Integer beforeYear,
@Parameter(description = "변화 후 년도", required = true, example = "2024") @RequestParam
@Parameter(description = "변화 후 년도", required = false, example = "2024") @RequestParam(required = false)
Integer afterYear) {
return ApiResponseDto.ok(
trainingDataReviewService.getCogImageUrl(mapSheetNum, beforeYear, afterYear));