From 4be112f1de26f287fb1081f6ef771a9f7ac9ccfa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?dean=5B=EB=B0=B1=EB=B3=91=EB=82=A8=5D?= Date: Mon, 22 Dec 2025 20:29:26 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20=EC=97=85=EB=A1=9C=EB=93=9C=20=EA=B2=BD?= =?UTF-8?q?=EB=A1=9C=20check?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapsheet/service/MapSheetMngService.java | 26 ++++++++++++++----- 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/src/main/java/com/kamco/cd/kamcoback/mapsheet/service/MapSheetMngService.java b/src/main/java/com/kamco/cd/kamcoback/mapsheet/service/MapSheetMngService.java index 0fcf9706..d243dde5 100644 --- a/src/main/java/com/kamco/cd/kamcoback/mapsheet/service/MapSheetMngService.java +++ b/src/main/java/com/kamco/cd/kamcoback/mapsheet/service/MapSheetMngService.java @@ -19,11 +19,13 @@ import java.nio.file.Paths; import java.nio.file.StandardCopyOption; import java.util.List; import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; import org.springframework.data.domain.Page; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import org.springframework.web.multipart.MultipartFile; +@Slf4j @Service @RequiredArgsConstructor @Transactional(readOnly = true) @@ -85,6 +87,7 @@ public class MapSheetMngService { } // 파일검증용 임시저장 폴더 확인 + log.info("TmpPath > {}", tmpPath); if (!FIleChecker.mkDir(tmpPath)) { return new DmlReturn("fail", "CREATE TEMP FOLDER ERROR"); } @@ -127,10 +130,15 @@ public class MapSheetMngService { if (tfwCnt > 0 || tifCnt > 0) { String tfwtifMsg = ""; - if (tfwCnt > 0) tfwtifMsg = tfwFile.getOriginalFilename(); + if (tfwCnt > 0) { + tfwtifMsg = tfwFile.getOriginalFilename(); + } if (tifCnt > 0) { - if (tfwCnt > 0) tfwtifMsg = "," + tifFile.getOriginalFilename(); - else tfwtifMsg = tifFile.getOriginalFilename(); + if (tfwCnt > 0) { + tfwtifMsg = "," + tifFile.getOriginalFilename(); + } else { + tfwtifMsg = tifFile.getOriginalFilename(); + } } return new DmlReturn("duplicate", tfwtifMsg); } @@ -149,8 +157,12 @@ public class MapSheetMngService { return new DmlReturn("fail", "UPLOAD ERROR"); } - if (!FIleChecker.cmmndGdalInfo(tifTmpPath)) return new DmlReturn("fail", "TIF TYPE ERROR"); - if (!FIleChecker.checkTfw(tfwTmpPath)) return new DmlReturn("fail", "TFW TYPE ERROR"); + if (!FIleChecker.cmmndGdalInfo(tifTmpPath)) { + return new DmlReturn("fail", "TIF TYPE ERROR"); + } + if (!FIleChecker.checkTfw(tfwTmpPath)) { + return new DmlReturn("fail", "TFW TYPE ERROR"); + } // 싱크파일목록으로 업로드 경로 확인 List mngFiles = mapSheetMngCoreService.findIdToMapSheetFileList(hstUid); @@ -247,7 +259,9 @@ public class MapSheetMngService { } // 중복제거 확인후 처리상태(DONE)변경 - if (hstUid > 0) mapSheetMngCoreService.updateByHstUidSyncCheckState(hstUid); + if (hstUid > 0) { + mapSheetMngCoreService.updateByHstUidSyncCheckState(hstUid); + } return new DmlReturn("success", fileUids.size() + "개 파일이 삭제되었습니다."); }