법인 정보 관리 페이지 수정

This commit is contained in:
Rinjae
2026-01-17 21:12:37 +09:00
parent 5710f54851
commit 5e8eeecf29
@@ -2,7 +2,7 @@ package com.eactive.eai.rms.onl.manage.authserver.client;
import com.eactive.apim.portal.app.entity.Credential;
import com.eactive.apim.portal.portalorg.entity.PortalOrg;
import com.eactive.eai.data.entity.onl.eaimsg.EAIMessageEntity;
import com.eactive.eai.data.entity.onl.message.EAIMessageEntity;
import com.eactive.eai.rms.common.datasource.DataSourceContextHolder;
import com.eactive.eai.rms.common.datasource.DataSourceType;
import com.eactive.eai.rms.common.datasource.DataSourceTypeManager;
@@ -130,12 +130,24 @@ public class ClientManService extends OnlBaseService {
// 3. API 유효성 검증 (APIGW 스키마)
List<String> invalidApis = new ArrayList<>();
if (clientEntity.getApiList() != null) {
for (EAIMessageEntity apiEntity : clientEntity.getApiList()) {
String eaiSvcName = apiEntity.getEaiSvcName();
// APIGW에 실제 API 존재하는지 확인
if (!eaiMessageService.existsById(eaiSvcName)) {
invalidApis.add(eaiSvcName);
List<String> requestedApiIds = new ArrayList<>();
if (clientEntity.getApiList() != null && !clientEntity.getApiList().isEmpty()) {
// ClientEntity의 apiList에서 API ID 목록 추출
requestedApiIds = clientEntity.getApiList().stream()
.map(EAIMessageEntity::getEaisvcname)
.collect(Collectors.toList());
// APIGW에 실제 존재하는 API 조회
List<EAIMessageEntity> existingApis = eaiMessageService.findByEaisvcnameList(requestedApiIds);
List<String> existingApiIds = existingApis.stream()
.map(EAIMessageEntity::getEaisvcname)
.collect(Collectors.toList());
// 요청된 API 중 존재하지 않는 API 찾기
for (String apiId : requestedApiIds) {
if (!existingApiIds.contains(apiId)) {
invalidApis.add(apiId);
}
}
}
@@ -242,8 +254,7 @@ public class ClientManService extends OnlBaseService {
// 앱 상태
credentialUI.setAppstatus(clientEntity.getAppstatus());
credentialUI.setDailytokenlimit(Integer.parseInt(
StringUtils.defaultIfBlank(clientEntity.getDailytokenlimit(), "0")));
credentialUI.setDailytokenlimit(clientEntity.getDailytokenlimit());
// 수정 정보
credentialUI.setModifiedby(clientEntity.getModifiedby());
@@ -254,7 +265,7 @@ public class ClientManService extends OnlBaseService {
if (clientEntity.getApiList() != null) {
for (EAIMessageEntity apiEntity : clientEntity.getApiList()) {
ApiSpecInfoUI apiUI = new ApiSpecInfoUI();
apiUI.setApiId(apiEntity.getEaiSvcName());
apiUI.setApiId(apiEntity.getEaisvcname());
apiList.add(apiUI);
}
}