From 1a4371ead391d86f2800920331b602ecab1218a3 Mon Sep 17 00:00:00 2001 From: "gayoun.park" Date: Mon, 26 Jan 2026 11:48:15 +0900 Subject: [PATCH] =?UTF-8?q?=EC=98=81=EC=83=81=EA=B4=80=EB=A6=AC=20?= =?UTF-8?q?=EC=88=98=EC=A0=95=20-=20=ED=99=95=EC=9E=A5=EC=9E=90=20?= =?UTF-8?q?=EB=8C=80=EB=AC=B8=EC=9E=90=20ignore,=20=ED=8C=8C=EC=9D=BC?= =?UTF-8?q?=EA=B2=BD=EB=A1=9C=20=EC=B6=94=EA=B0=80,=20=EC=98=A4=EB=A5=98?= =?UTF-8?q?=EB=AA=A9=EB=A1=9D=20=EB=93=B1=EB=A1=9D=EC=9D=BC=20=EA=B8=B0?= =?UTF-8?q?=EC=A4=80=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapsheet/dto/MapSheetMngDto.java | 48 ++++++++++--------- .../mapsheet/MapSheetMngRepositoryImpl.java | 6 ++- .../service/MapSheetMngFileJobService.java | 20 +++++--- 3 files changed, 44 insertions(+), 30 deletions(-) diff --git a/src/main/java/com/kamco/cd/kamcoback/mapsheet/dto/MapSheetMngDto.java b/src/main/java/com/kamco/cd/kamcoback/mapsheet/dto/MapSheetMngDto.java index dafb86f7..eb4ee0c2 100644 --- a/src/main/java/com/kamco/cd/kamcoback/mapsheet/dto/MapSheetMngDto.java +++ b/src/main/java/com/kamco/cd/kamcoback/mapsheet/dto/MapSheetMngDto.java @@ -20,6 +20,27 @@ import org.springframework.data.domain.Sort; public class MapSheetMngDto { + @Getter + @AllArgsConstructor + public enum MapSheetState implements EnumType { + // @formatter:off + DONE("완료"), + NOTYET("처리대기"); + // @formatter:on + + private final String message; + + @Override + public String getId() { + return name(); + } + + @Override + public String getText() { + return message; + } + } + @Schema(name = "MngSearchReq", description = "영상관리 검색 요청") @Getter @Setter @@ -233,6 +254,7 @@ public class MapSheetMngDto { private String errorCheckStateName; private String errorCheckTfwFileName; private String errorCheckTifFileName; + private String mapSheetPath; // private List fileArray; @@ -251,7 +273,8 @@ public class MapSheetMngDto { String syncTifFileName, String errorCheckState, String errorCheckTfwFileName, - String errorCheckTifFileName) { + String errorCheckTifFileName, + String mapSheetPath) { this.hstUid = hstUid; this.mngYyyy = mngYyyy; this.mapSheetNum = mapSheetNum; @@ -269,6 +292,7 @@ public class MapSheetMngDto { this.errorCheckStateName = getSyncStateName(errorCheckState); this.errorCheckTfwFileName = errorCheckTfwFileName; this.errorCheckTifFileName = errorCheckTifFileName; + this.mapSheetPath = mapSheetPath; } private String getSyncStateName(String enumId) { @@ -366,27 +390,6 @@ public class MapSheetMngDto { } } - @Getter - @AllArgsConstructor - public enum MapSheetState implements EnumType { - // @formatter:off - DONE("완료"), - NOTYET("처리대기"); - // @formatter:on - - private final String message; - - @Override - public String getId() { - return name(); - } - - @Override - public String getText() { - return message; - } - } - // 연도리스틀 조회시 사용하는 request Dto @Getter @Setter @@ -461,6 +464,7 @@ public class MapSheetMngDto { @NoArgsConstructor @AllArgsConstructor public static class MngYyyyDto { + private Integer yyyy; private String mngPath; } diff --git a/src/main/java/com/kamco/cd/kamcoback/postgres/repository/mapsheet/MapSheetMngRepositoryImpl.java b/src/main/java/com/kamco/cd/kamcoback/postgres/repository/mapsheet/MapSheetMngRepositoryImpl.java index 7fae7e68..d87fe15e 100644 --- a/src/main/java/com/kamco/cd/kamcoback/postgres/repository/mapsheet/MapSheetMngRepositoryImpl.java +++ b/src/main/java/com/kamco/cd/kamcoback/postgres/repository/mapsheet/MapSheetMngRepositoryImpl.java @@ -379,13 +379,15 @@ public class MapSheetMngRepositoryImpl extends QuerydslRepositorySupport mapInkx5kEntity.mapidNm, mapSheetMngHstEntity.mapSheetNum) .as("mapSrcName"), mapInkx5kEntity.fid, - mapSheetMngHstEntity.createdDate, + mapSheetMngHstEntity.syncCheckEndDttm.coalesce( + mapSheetMngHstEntity.createdDate), mapSheetMngHstEntity.syncState, mapSheetMngHstEntity.syncTfwFileName, mapSheetMngHstEntity.syncTifFileName, mapSheetMngHstEntity.syncCheckState, mapSheetMngHstEntity.syncCheckTfwFileName, - mapSheetMngHstEntity.syncCheckTifFileName)) + mapSheetMngHstEntity.syncCheckTifFileName, + mapSheetMngHstEntity.mapSheetPath)) .from(mapSheetMngHstEntity) .innerJoin(mapInkx5kEntity) .on( diff --git a/src/main/java/com/kamco/cd/kamcoback/scheduler/service/MapSheetMngFileJobService.java b/src/main/java/com/kamco/cd/kamcoback/scheduler/service/MapSheetMngFileJobService.java index f46b611b..8758120b 100644 --- a/src/main/java/com/kamco/cd/kamcoback/scheduler/service/MapSheetMngFileJobService.java +++ b/src/main/java/com/kamco/cd/kamcoback/scheduler/service/MapSheetMngFileJobService.java @@ -85,7 +85,9 @@ public class MapSheetMngFileJobService { // 도엽별 파일 체크 진행중으로 변경 item.setDataState("PROCESSING"); item.setUseInference("USE"); - if (exceptCheckCnt == 0) item.setUseInference("EXCEPT"); + if (exceptCheckCnt == 0) { + item.setUseInference("EXCEPT"); + } mngHstDataSyncStateUpdate(item); // 1. MngHstDto 객체의 필드 값에 접근 @@ -133,7 +135,9 @@ public class MapSheetMngFileJobService { syncState = ""; syncCheckState = ""; - if (tfwCnt == 0 && tifCnt == 0) syncState = "NOFILE"; + if (tfwCnt == 0 && tifCnt == 0) { + syncState = "NOFILE"; + } for (Basic item2 : basicList) { // System.out.println("path: " + item2.getParentPath()); @@ -151,7 +155,7 @@ public class MapSheetMngFileJobService { addReq.setHstUid(item.getHstUid()); fileState = "DONE"; - if (item2.getExtension().equals("tfw")) { + if ("tfw".equalsIgnoreCase(item2.getExtension())) { if (tifCnt == 0) { fileState = "NOTPAIR"; syncState = fileState; @@ -169,7 +173,7 @@ public class MapSheetMngFileJobService { item.setMapSheetPath(item2.getParentPath()); item.setSyncTfwFileName(item2.getFileNm()); - } else if (item2.getExtension().equals("tif")) { + } else if ("tif".equalsIgnoreCase(item2.getExtension())) { if (tfwCnt == 0) { fileState = "NOTPAIR"; syncState = fileState; @@ -195,7 +199,9 @@ public class MapSheetMngFileJobService { // 도엽별 파일 체크 완료로 변경 item.setDataState("DONE"); - if (syncState.isEmpty()) syncState = "DONE"; + if (syncState.isEmpty()) { + syncState = "DONE"; + } item.setSyncState(syncState); mngHstDataSyncStateUpdate(item); @@ -230,7 +236,9 @@ public class MapSheetMngFileJobService { public Long mapSheetAutoExceptionUpdate(int mngYyyy, String mapSheetNum) { // 2025년 이전 파일싱크는 무조건 이전3년이 존재하지 않으므로 자동추론제외를 진행하지 않는다.(전년도 파일이 무조건 존재하는 것으로 리턴) - if (syncAutoExceptionStartYear > mngYyyy) return 1L; + if (syncAutoExceptionStartYear > mngYyyy) { + return 1L; + } // List mapSheetNums = new ArrayList<>(); // mapSheetNums.add(mapSheetNum);