From 67679f4e713bc581917f3818ffb783df43879459 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9C=A0=EC=A7=80=EC=9D=B8?= Date: Wed, 5 Nov 2025 15:20:14 +0900 Subject: [PATCH] =?UTF-8?q?=EB=B9=84=ED=99=9C=EC=84=B1=ED=99=94=20?= =?UTF-8?q?=EB=90=9C=20API=20=EC=84=9C=EB=B9=84=EC=8A=A4=20=EB=A7=89?= =?UTF-8?q?=EA=B8=B0=20=EC=B2=98=EB=A6=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/geoinfo/service/GeoinfoApiV1Mapper.java | 2 ++ .../geoinfo/service/impl/GeoinfoApiV1ServiceImpl.java | 11 +++++++++++ .../sqlmap/mapper/api/geoinfo/GeoinfoApiV1Mapper.xml | 9 ++++++++- 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/src/main/java/geoinfo/api/geoinfo/service/GeoinfoApiV1Mapper.java b/src/main/java/geoinfo/api/geoinfo/service/GeoinfoApiV1Mapper.java index e403339e..9fdd3a1c 100644 --- a/src/main/java/geoinfo/api/geoinfo/service/GeoinfoApiV1Mapper.java +++ b/src/main/java/geoinfo/api/geoinfo/service/GeoinfoApiV1Mapper.java @@ -30,6 +30,8 @@ public interface GeoinfoApiV1Mapper { // 프로젝트 정보 (Project Info) // ================================================================================================== + /** API ON/OFF 처리를 위한 활성상태 조회 처리 */ + public String selectApiActiveYn(String spNamep) throws SQLException; public ArrayList spGetTblProjectInfo(HashMap params) throws SQLException; public int spCntTblProjectInfo(HashMap params) throws SQLException; public ArrayList spGetSelectclassInfoP(HashMap params) throws SQLException; diff --git a/src/main/java/geoinfo/api/geoinfo/service/impl/GeoinfoApiV1ServiceImpl.java b/src/main/java/geoinfo/api/geoinfo/service/impl/GeoinfoApiV1ServiceImpl.java index 26a5765e..302ef3f7 100644 --- a/src/main/java/geoinfo/api/geoinfo/service/impl/GeoinfoApiV1ServiceImpl.java +++ b/src/main/java/geoinfo/api/geoinfo/service/impl/GeoinfoApiV1ServiceImpl.java @@ -36,6 +36,17 @@ public class GeoinfoApiV1ServiceImpl implements GeoinfoApiV1Service { //호출 프로시저 유효성 체크 spName = spName.trim(); + // API ACTIVE_YN 판별하여 'N'일 경우 일시중단상태. + String apiStatus = geoinfoApiV1Mapper.selectApiActiveYn(spName); + if (apiStatus != null && "N".equals(apiStatus)) { + // 성공 응답 기본값 설정 + jsonResponse.put("resultCode", 0); + jsonResponse.put("result", "true"); + jsonResponse.put("message", "DISABLE"); + + // 성공 코드 반환 + return 0; + } // 서비스 이름에 따라 분기 처리 if ("sp-get-tbl-project-info".equalsIgnoreCase(spName)) { diff --git a/src/main/resources/egovframework/sqlmap/mapper/api/geoinfo/GeoinfoApiV1Mapper.xml b/src/main/resources/egovframework/sqlmap/mapper/api/geoinfo/GeoinfoApiV1Mapper.xml index ad00aa0d..3ed63778 100644 --- a/src/main/resources/egovframework/sqlmap/mapper/api/geoinfo/GeoinfoApiV1Mapper.xml +++ b/src/main/resources/egovframework/sqlmap/mapper/api/geoinfo/GeoinfoApiV1Mapper.xml @@ -6,7 +6,14 @@ - + + + +