13 Commits

Author SHA1 Message Date
eastargh 70c2ac8376 서버 등록시 중복체크
eapim-admin CI / build (push) Has been cancelled
2026-07-16 14:52:36 +09:00
eastargh 21c493cb0e 통계 화면 레이아웃 조정
eapim-admin CI / build (push) Has been cancelled
2026-07-16 11:11:01 +09:00
eastargh b9c6a0da06 파이차트 글자 겹쳐보이는 버그 수정 (legend 오른쪽으로 이동)
eapim-admin CI / build (push) Has been cancelled
2026-07-16 10:14:37 +09:00
eastargh a0725b57a6 sms->kakao로 통일
eapim-admin CI / build (push) Has been cancelled
2026-07-16 09:27:37 +09:00
eastargh 50bfcacf27 전문레이아웃 변환 매핑 - api선택 팝업 추가
eapim-admin CI / build (push) Has been cancelled
2026-07-15 16:52:34 +09:00
eastargh f400f0322f 유량제어 이력 검색조건 추가
eapim-admin CI / build (push) Has been cancelled
2026-07-14 15:05:57 +09:00
eastargh d0cd8118f3 유량제어관련 메뉴 - 사용여부 검색조건 추가
eapim-admin CI / build (push) Has been cancelled
2026-07-14 11:30:55 +09:00
Rinjae 07e65c055b - JSP: OpenAPI Spec 버튼 상태 수정 - NEW → DETAIL로 변경
eapim-admin CI / build (push) Has been cancelled
- Service: BIGDECIMAL 매핑 추가 - 반환 유형 'number'
- Monitoring: Properties 초기화 및 null 체크 로직 추가
- JS: 샘플 응답 상태 시 안내 메시지 추가
2026-07-14 11:11:24 +09:00
eastargh af8a9cca51 프라퍼티 정리
eapim-admin CI / build (push) Has been cancelled
2026-07-13 17:47:35 +09:00
eastargh 39a09d0f5d 유량제어 url 특수문자 escape 2026-07-13 17:47:08 +09:00
Rinjae 5b940717c4 Merge remote-tracking branch 'origin/master'
eapim-admin CI / build (push) Has been cancelled
2026-07-13 15:30:13 +09:00
Rinjae 8ccf52fd66 - JSP: OpenAPI Spec 모달 처리 개선 - 동적 크기 조절 및 스타일 추가
- Service: GET/DELETE 요청 바디 항목→쿼리 파라미터 매핑 로직 추가
- JS: 요청 정보 진입 시 탭 자동 전환 로직(firstReqTabWithData) 구현
2026-07-13 15:30:08 +09:00
eastargh dedc58a07f 유량제어 추가임계치가 null or 단위선택 않하면 0으로 설정
eapim-admin CI / build (push) Has been cancelled
2026-07-13 15:24:30 +09:00
34 changed files with 838 additions and 576 deletions
+17 -2
View File
@@ -301,7 +301,7 @@
function goStep(n) { function goStep(n) {
if (n < 1 || n > STEPS.length) return; if (n < 1 || n > STEPS.length) return;
state.step = n; state.step = n;
if (n === 2) state.reqInfoTab = 'body'; // 요청/응답 정보: 진입 시 항상 Body 먼저 if (n === 2) state.reqInfoTab = firstReqTabWithData(); // 요청 정보: 값 있는 탭(Header→Parameter→Body 순) 먼저
if (n === 3) state.resInfoTab = 'body'; if (n === 3) state.resInfoTab = 'body';
renderStepper(); renderStepper();
renderForm(); renderForm();
@@ -439,6 +439,19 @@
+ '</div>'; + '</div>';
} }
// 요청 정보 진입 시 먼저 보일 서브탭 = 값이 든 첫 탭(Header→Parameter→Body 순).
// 보통 GET 은 Parameter(query), POST 는 Body 에만 값이 있음. 전부 비면 Body 로.
function firstReqTabWithData() {
var params = (state.data && state.data.parameters) || [];
var hasHeader = params.some(function (p) { return p.in === 'header'; });
var hasParam = params.some(function (p) { return p.in === 'query'; });
var hasBody = !!(state.data && state.data.requestBody && state.data.requestBody.schema && state.data.requestBody.schema.length);
if (hasHeader) return 'header';
if (hasParam) return 'param';
if (hasBody) return 'body';
return 'body';
}
// Step 2 — 요청 정보 (Header / Parameter / Body / API 설명(HTML)) // Step 2 — 요청 정보 (Header / Parameter / Body / API 설명(HTML))
function renderReqInfo(root) { function renderReqInfo(root) {
const tab = state.reqInfoTab || 'body'; const tab = state.reqInfoTab || 'body';
@@ -991,7 +1004,9 @@
['sample', 'mock', 'gw'].map(v => ['sample', 'mock', 'gw'].map(v =>
`<label class="inline-flex items-center gap-1 text-sm mr-3"><input type="radio" name="portal-rt" data-portal-rt="${v}" ${rt === v ? 'checked' : ''}> ${v === 'gw' ? 'GW' : v}</label>` `<label class="inline-flex items-center gap-1 text-sm mr-3"><input type="radio" name="portal-rt" data-portal-rt="${v}" ${rt === v ? 'checked' : ''}> ${v === 'gw' ? 'GW' : v}</label>`
).join('') + ).join('') +
`<div class="mt-2 text-xs text-slate-500">실제 호출 주소: <code id="resolved-call-url" class="font-mono text-slate-700 break-all">${escapeHtml(resolvedCallUrl())}</code></div>` + (rt === 'sample'
? `<div class="mt-2 text-xs text-slate-500">응답 샘플을 바로 리턴합니다.</div>`
: `<div class="mt-2 text-xs text-slate-500">실제 호출 주소: <code id="resolved-call-url" class="font-mono text-slate-700 break-all">${escapeHtml(resolvedCallUrl())}</code></div>`) +
(rt === 'gw' ? `<div class="mt-1 text-xs text-slate-400">GW 주소는 포탈 설정(PTL_PROPERTY, 그룹 Portal)의 <code class="font-mono">djb.gateway.base-url</code> 값을 사용합니다.</div>` : '') + (rt === 'gw' ? `<div class="mt-1 text-xs text-slate-400">GW 주소는 포탈 설정(PTL_PROPERTY, 그룹 Portal)의 <code class="font-mono">djb.gateway.base-url</code> 값을 사용합니다.</div>` : '') +
'</div>') + '</div>') +
(rt === 'mock' ? fieldRow('Mock Server URL', input(p.mockUrl || '', 'data-portal="mockUrl"', { placeholder: 'https://mock.example.com' }), { hint: 'Mock 응답을 제공할 서버의 기본 URL. 응답 유형이 Mock 일 때 개발자포탈이 이 주소로 요청을 전달하고, Swagger 스펙의 서버 주소로도 사용됩니다.' }) : '') (rt === 'mock' ? fieldRow('Mock Server URL', input(p.mockUrl || '', 'data-portal="mockUrl"', { placeholder: 'https://mock.example.com' }), { hint: 'Mock 응답을 제공할 서버의 기본 URL. 응답 유형이 Mock 일 때 개발자포탈이 이 주소로 요청을 전달하고, Swagger 스펙의 서버 주소로도 사용됩니다.' }) : '')
+33 -268
View File
@@ -1,298 +1,63 @@
// 계좌이체 API 모의 데이터 // OpenAPI 에디터 초기 상태 골격(빈 껍데기).
// locked: true 인 필드는 게이트웨이가 자동 주입한 값(회색 + 자물쇠) // - specToData() 가 deepClone 하여 서버 spec 값으로 덮어쓰는 구조 기준값.
// locked: false / 미지정 인 필드는 사용자가 자유롭게 편집 // - 실제 데모/샘플 값은 두지 않는다(팝업은 항상 서버 spec 로드 후 렌더).
// - docOptions 만 기능 기본값으로 유지(문서 미리보기 옵션).
// locked:true = 게이트웨이 자동 주입(회색+자물쇠) / locked:false = 사용자 편집.
window.SAMPLE_DATA = (function () { window.SAMPLE_DATA = (function () {
function f() { return { value: '', locked: false }; }
return { return {
info: { info: {
title: { value: '계좌이체 API', locked: false }, title: f(),
version: { value: '1.0.0', locked: false }, version: f(),
summary: { value: '', locked: false }, summary: f(),
description: { value: '', locked: false }, description: f(),
termsOfService: { value: '', locked: false }, termsOfService: f(),
contact: { contact: { name: f(), email: f(), url: f() },
name: { value: 'DJB API Team', locked: false }, license: { name: f(), url: f() }
email: { value: 'api@djb.co.kr', locked: false },
url: { value: '', locked: false }
},
license: {
name: { value: '', locked: false },
url: { value: '', locked: false }
}
}, },
tags: [ tags: [],
{ name: 'transfer', description: '계좌이체 관련 API' }
],
externalDocs: { externalDocs: { description: f(), url: f() },
description: { value: '', locked: false },
url: { value: '', locked: false }
},
servers: [ servers: [],
{
url: { value: 'https://api-dev.djb.co.kr', locked: true },
env: 'development',
description: { value: '개발 환경', locked: false }
},
{
url: { value: 'https://api-stg.djb.co.kr', locked: true },
env: 'staging',
description: { value: '스테이징 환경', locked: false }
},
{
url: { value: 'https://api.djb.co.kr', locked: true },
env: 'production',
description: { value: '운영 환경', locked: false }
}
],
serverVariables: [ serverVariables: [],
{
name: { value: 'basePath', locked: true },
default: { value: '/v1', locked: false },
enumStr: { value: '/v1,/v2', locked: false },
description: { value: 'API 버전 경로', locked: false }
}
],
operation: { operation: {
method: { value: 'POST', locked: true }, method: f(),
path: { value: '/v1/accounts/transfer', locked: true }, path: f(),
operationId: { value: 'transferAccount', locked: false }, operationId: f(),
summary: { value: '', locked: false }, summary: f(),
description: { value: '', locked: false }, description: f(),
tags: { value: ['transfer'], locked: false }, tags: { value: [], locked: false },
deprecated: { value: false, locked: false } deprecated: { value: false, locked: false }
}, },
// 파라미터 (Path/Query/Header/Cookie) // 파라미터 (Path/Query/Header/Cookie)
parameters: [ parameters: [],
{
in: 'header',
name: { value: 'X-Request-Id', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: 'uuid', locked: false },
maxLength: { value: '', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '', locked: false }
}
],
// Request Body 스키마 (중첩 3단) // Request Body 스키마
requestBody: { requestBody: {
mediaType: 'application/json', mediaType: 'application/json',
required: { value: true, locked: true }, required: { value: false, locked: false },
schema: [ schema: []
{
name: { value: 'transactionId', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '40', locked: false },
pattern: { value: '^tx-[0-9a-zA-Z-]+$', locked: false },
description: { value: '', locked: false },
example: { value: 'tx-20260522-001', locked: false },
children: null
},
{
name: { value: 'sender', locked: true },
type: { value: 'object', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '', locked: false },
pattern: { value: '', locked: false },
description: { value: '송금인 정보', locked: false },
example: { value: '', locked: false },
children: [
{
name: { value: 'accountNumber', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '20', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '110-1234-567890', locked: false },
children: null
},
{
name: { value: 'bankCode', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '3', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '088', locked: false },
children: null
},
{
name: { value: 'holderName', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '60', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '김철수', locked: false },
children: null
}
]
},
{
name: { value: 'receiver', locked: true },
type: { value: 'object', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '', locked: false },
pattern: { value: '', locked: false },
description: { value: '수취인 정보', locked: false },
example: { value: '', locked: false },
children: [
{
name: { value: 'accountNumber', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '20', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '111-2345-678901', locked: false },
children: null
},
{
name: { value: 'bankCode', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '3', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '020', locked: false },
children: null
},
{
name: { value: 'holderName', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '60', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '이영희', locked: false },
children: null
}
]
},
{
name: { value: 'amount', locked: true },
type: { value: 'object', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '', locked: false },
pattern: { value: '', locked: false },
description: { value: '이체 금액', locked: false },
example: { value: '', locked: false },
children: [
{
name: { value: 'value', locked: true },
type: { value: 'integer', locked: true },
required: { value: true, locked: true },
format: { value: 'int64', locked: false },
maxLength: { value: '', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '50000', locked: false },
children: null
},
{
name: { value: 'currency', locked: true },
type: { value: 'string', locked: true },
required: { value: true, locked: true },
format: { value: '', locked: false },
maxLength: { value: '3', locked: false },
pattern: { value: '^[A-Z]{3}$', locked: false },
description: { value: 'ISO 4217 통화코드', locked: false },
example: { value: 'KRW', locked: false },
children: null
}
]
},
{
name: { value: 'memo', locked: true },
type: { value: 'string', locked: true },
required: { value: false, locked: true },
format: { value: '', locked: false },
maxLength: { value: '100', locked: false },
pattern: { value: '', locked: false },
description: { value: '', locked: false },
example: { value: '5월 회비', locked: false },
children: null
}
]
}, },
// 응답 스키마 (상태코드 별) // 응답 스키마 (상태코드 별)
responses: { responses: {
'200': { '200': { description: f(), schema: [] }
description: { value: '이체 성공', locked: false },
schema: [
{ name: { value: 'transactionId', locked: true }, type: { value: 'string', locked: true }, required: { value: true, locked: true }, format: { value: '', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: 'tx-20260522-001', locked: false }, children: null },
{ name: { value: 'status', locked: true }, type: { value: 'string', locked: true }, required: { value: true, locked: true }, format: { value: '', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: 'COMPLETED', locked: false }, children: null },
{ name: { value: 'completedAt', locked: true }, type: { value: 'string', locked: true }, required: { value: true, locked: true }, format: { value: 'date-time', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: '2026-05-22T10:00:00Z', locked: false }, children: null },
{
name: { value: 'balance', locked: true }, type: { value: 'object', locked: true }, required: { value: true, locked: true }, format: { value: '', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '잔액 정보', locked: false }, example: { value: '', locked: false },
children: [
{ name: { value: 'before', locked: true }, type: { value: 'integer', locked: true }, required: { value: true, locked: true }, format: { value: 'int64', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: '1000000', locked: false }, children: null },
{ name: { value: 'after', locked: true }, type: { value: 'integer', locked: true }, required: { value: true, locked: true }, format: { value: 'int64', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: '950000', locked: false }, children: null }
]
}
]
},
'400': {
description: { value: '잘못된 요청', locked: false },
schema: [
{
name: { value: 'error', locked: true }, type: { value: 'object', locked: true }, required: { value: true, locked: true }, format: { value: '', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: '', locked: false },
children: [
{ name: { value: 'code', locked: true }, type: { value: 'string', locked: true }, required: { value: true, locked: true }, format: { value: '', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: 'INVALID_AMOUNT', locked: false }, children: null },
{ name: { value: 'message', locked: true }, type: { value: 'string', locked: true }, required: { value: true, locked: true }, format: { value: '', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: '금액이 올바르지 않습니다', locked: false }, children: null },
{ name: { value: 'details', locked: true }, type: { value: 'array', locked: true }, required: { value: false, locked: true }, format: { value: '', locked: false }, maxLength: { value: '', locked: false }, pattern: { value: '', locked: false }, description: { value: '', locked: false }, example: { value: '', locked: false }, itemsType: { value: 'string', locked: false }, children: null }
]
}
]
},
'401': { description: { value: '인증 실패', locked: false }, schema: [] },
'500': { description: { value: '서버 오류', locked: false }, schema: [] }
}, },
// 보안 스킴 // 보안 스킴
securitySchemes: [ securitySchemes: [],
{ globalSecurity: [],
key: 'ApiKeyAuth',
type: 'apiKey',
locked: true,
name: { value: 'X-API-Key', locked: true },
in: { value: 'header', locked: true },
description: { value: '', locked: false }
}
],
globalSecurity: ['ApiKeyAuth'],
// 예제 // 예제
examples: { examples: {
request: { request: {},
'application/json': { response: {}
default: '{\n "transactionId": "tx-20260522-001",\n "sender": {\n "accountNumber": "110-1234-567890",\n "bankCode": "088",\n "holderName": "김철수"\n },\n "receiver": {\n "accountNumber": "111-2345-678901",\n "bankCode": "020",\n "holderName": "이영희"\n },\n "amount": {\n "value": 50000,\n "currency": "KRW"\n },\n "memo": "5월 회비"\n}'
}
},
response: {
'200': { body: '{\n "transactionId": "tx-20260522-001",\n "status": "COMPLETED"\n}', headers: [ { name: 'X-RateLimit-Remaining', type: 'integer', description: '남은 요청 횟수', example: '99' } ] }
}
}, },
// 문서 옵션 // 문서 옵션
@@ -25,7 +25,7 @@ $(document).ready(function() {
datatype:"json", datatype:"json",
mtype: 'POST', mtype: 'POST',
url: url, url: url,
postData : { cmd : 'LIST', searchName: $('input[name=searchName]').val()}, postData : { cmd : 'LIST', searchName: $('input[name=searchName]').val(), searchUseYn: $('select[name=searchUseYn]').val()},
colNames:['<%= localeMessage.getString("infAdpConMan.adaNm") %>', colNames:['<%= localeMessage.getString("infAdpConMan.adaNm") %>',
'<%= localeMessage.getString("infAdpConMan.adaDes") %>', '<%= localeMessage.getString("infAdpConMan.adaDes") %>',
'<%= localeMessage.getString("infAdpConMan.thrPerSecond") %>', '<%= localeMessage.getString("infAdpConMan.thrPerSecond") %>',
@@ -62,6 +62,7 @@ $(document).ready(function() {
url2 += '&menuId='+'${param.menuId}'; url2 += '&menuId='+'${param.menuId}';
//검색값 //검색값
url2 += '&searchName='+$("input[name=searchName]").val(); url2 += '&searchName='+$("input[name=searchName]").val();
url2 += '&searchUseYn='+$("select[name=searchUseYn]").val();
//key값 //key값
url2 += '&name='+name; url2 += '&name='+name;
goNav(url2); goNav(url2);
@@ -80,7 +81,7 @@ $(document).ready(function() {
resizeJqGridWidth('grid','content_middle','1000'); resizeJqGridWidth('grid','content_middle','1000');
$("#btn_search").click(function(){ $("#btn_search").click(function(){
$("#grid").setGridParam({ postData: { searchName: $('input[name=searchName]').val()}, page:1 }).trigger("reloadGrid"); $("#grid").setGridParam({ postData: { searchName: $('input[name=searchName]').val(), searchUseYn: $('select[name=searchUseYn]').val()}, page:1 }).trigger("reloadGrid");
}); });
$("#btn_new").click(function(){ $("#btn_new").click(function(){
var url2 = url_view; var url2 = url_view;
@@ -126,6 +127,16 @@ $(document).ready(function() {
<tr> <tr>
<th style="width:180px;"><%= localeMessage.getString("infAdpConMan.adaNm") %></th> <th style="width:180px;"><%= localeMessage.getString("infAdpConMan.adaNm") %></th>
<td><input type="text" name="searchName" value="${param.searchName}"></td> <td><input type="text" name="searchName" value="${param.searchName}"></td>
<th style="width:180px;"><%= localeMessage.getString("infAdpConMan.useYn") %></th>
<td>
<div class="select-style">
<select name="searchUseYn">
<option value="">전체</option>
<option value="1">사용함</option>
<option value="0">사용안함</option>
</select>
</div>
</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
@@ -25,7 +25,7 @@ $(document).ready(function() {
datatype:"json", datatype:"json",
mtype: 'POST', mtype: 'POST',
url: url, url: url,
postData : { cmd : 'LIST', searchName: $('input[name=searchName]').val()}, postData : { cmd : 'LIST', searchName: $('input[name=searchName]').val(), searchUseYn: $('select[name=searchUseYn]').val()},
colNames:['클라이언트 ID', colNames:['클라이언트 ID',
'클라이언트명', '클라이언트명',
'<%= localeMessage.getString("infAdpConMan.thrPerSecond") %>', '<%= localeMessage.getString("infAdpConMan.thrPerSecond") %>',
@@ -62,6 +62,7 @@ $(document).ready(function() {
url2 += '&menuId='+'${param.menuId}'; url2 += '&menuId='+'${param.menuId}';
//검색값 //검색값
url2 += '&searchName='+$("input[name=searchName]").val(); url2 += '&searchName='+$("input[name=searchName]").val();
url2 += '&searchUseYn='+$("select[name=searchUseYn]").val();
//key값 //key값
url2 += '&name='+name; url2 += '&name='+name;
goNav(url2); goNav(url2);
@@ -80,7 +81,7 @@ $(document).ready(function() {
resizeJqGridWidth('grid','content_middle','1000'); resizeJqGridWidth('grid','content_middle','1000');
$("#btn_search").click(function(){ $("#btn_search").click(function(){
$("#grid").setGridParam({ postData: { searchName: $('input[name=searchName]').val()}, page:1 }).trigger("reloadGrid"); $("#grid").setGridParam({ postData: { searchName: $('input[name=searchName]').val(), searchUseYn: $('select[name=searchUseYn]').val()}, page:1 }).trigger("reloadGrid");
}); });
$("#btn_new").click(function(){ $("#btn_new").click(function(){
var url2 = url_view; var url2 = url_view;
@@ -90,7 +91,8 @@ $(document).ready(function() {
url2 += '&menuId='+'${param.menuId}'; url2 += '&menuId='+'${param.menuId}';
//검색값 //검색값
url2 += '&searchName='; url2 += '&searchName=';
url2 += '&searchUseYn='+$('select[name=searchUseYn]').val();
goNav(url2); goNav(url2);
}); });
@@ -124,6 +126,16 @@ $(document).ready(function() {
<tr> <tr>
<th style="width:180px;">클라이언트명</th> <th style="width:180px;">클라이언트명</th>
<td><input type="text" name="searchName" value="${param.searchName}"></td> <td><input type="text" name="searchName" value="${param.searchName}"></td>
<th style="width:180px;">사용여부</th>
<td>
<div class="select-style">
<select name="searchUseYn">
<option value="">전체</option>
<option value="1">사용함</option>
<option value="0">사용안함</option>
</select>
</div>
</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
@@ -298,6 +298,7 @@ $(document).ready(function() {
url: url, url: url,
data: postData, data: postData,
success: function(args) { success: function(args) {
console.log('mod', args);
showAlert("<%= localeMessage.getString("common.saveMsg") %>", { showAlert("<%= localeMessage.getString("common.saveMsg") %>", {
type: 'success', type: 'success',
title: '저장 완료', title: '저장 완료',
@@ -493,11 +494,6 @@ $(document).ready(function() {
<span class="bucket-summary-value" id="summaryThreshold">0<span class="unit">req</span></span> <span class="bucket-summary-value" id="summaryThreshold">0<span class="unit">req</span></span>
<span class="bucket-summary-sub" id="summaryThresholdCalc"></span> <span class="bucket-summary-sub" id="summaryThresholdCalc"></span>
</div> </div>
<div class="bucket-summary-item">
<span class="bucket-summary-label">적용 API</span>
<span class="bucket-summary-value" id="summaryActiveApi">0<span class="unit">개</span></span>
<span class="bucket-summary-sub" id="summaryActiveApiList"></span>
</div>
</div> </div>
</div> </div>
@@ -47,27 +47,40 @@ function groupNameFormat(cellvalue, options, rowObject) {
return strVal; return strVal;
} }
$(document).ready(function() { $(document).ready(function() {
$("input[name=searchStartYYYYMMDD],input[name=searchEndYYYYMMDD]").inputmask("yyyy-mm-dd",{'autoUnmask':true}); $("input[name=searchStartYYYYMMDD],input[name=searchEndYYYYMMDD]").inputmask("yyyy-mm-dd",{'autoUnmask':true});
$("input[name=searchStartTime],input[name=searchEndTime]").inputmask("hh:mm:ss",{'autoUnmask':true});
$("input[name=searchStartYYYYMMDD]").each(function(){ $("input[name=searchStartYYYYMMDD]").each(function(){
if ($(this).val() == undefined || $(this).val() == null || $(this).val() == ""){ if ($(this).val() == undefined || $(this).val() == null || $(this).val() == ""){
$(this).val(getToday()); $(this).val(getToday());
} }
}); });
$("input[name=searchEndYYYYMMDD]").each(function(){ $("input[name=searchEndYYYYMMDD]").each(function(){
if ($(this).val() == undefined || $(this).val() == null || $(this).val() == ""){ if ($(this).val() == undefined || $(this).val() == null || $(this).val() == ""){
$(this).val(getToday()); $(this).val(getToday());
} }
}); });
$("input[name=searchStartTime]").each(function(){
var gridPostData = getSearchForJqgrid("cmd","LIST"); //jqgrid에서는 object 로 if ($(this).val() == undefined || $(this).val() == null || $(this).val() == ""){
$(this).val("000000");
}
});
$("input[name=searchEndTime]").each(function(){
if ($(this).val() == undefined || $(this).val() == null || $(this).val() == ""){
$(this).val("235959");
}
});
var gridPostData = getSearchForJqgrid("cmd","LIST"); //jqgrid에서는 object 로
var start = $("input[name=searchStartYYYYMMDD]").val().replace(/-/gi,""); var start = $("input[name=searchStartYYYYMMDD]").val().replace(/-/gi,"");
var end = $("input[name=searchEndYYYYMMDD]").val().replace(/-/gi,""); var end = $("input[name=searchEndYYYYMMDD]").val().replace(/-/gi,"");
gridPostData["searchStartDate"] = start; gridPostData["searchStartDate"] = start;
gridPostData["searchEndDate"] = end; gridPostData["searchEndDate"] = end;
@@ -132,18 +145,20 @@ $(document).ready(function() {
resizeJqGridWidth('grid','content_middle','1000'); resizeJqGridWidth('grid','content_middle','1000');
$("#btn_search").click(function(){ $("#btn_search").click(function(){
var postData = getSearchForJqgrid("cmd","LIST"); //jqgrid에서는 object 로 var postData = getSearchForJqgrid("cmd","LIST"); //jqgrid에서는 object 로
var start = $("input[name=searchStartYYYYMMDD]").val().replace(/-/gi,""); var start = $("input[name=searchStartYYYYMMDD]").val().replace(/-/gi,"");
var end = $("input[name=searchEndYYYYMMDD]").val().replace(/-/gi,""); var end = $("input[name=searchEndYYYYMMDD]").val().replace(/-/gi,"");
var startTime = $("input[name=searchStartTime]").val();
if(start > end){ var endTime = $("input[name=searchEndTime]").val();
if((start + startTime) > (end + endTime)){
alert("조회기간을 확인해주세요."); alert("조회기간을 확인해주세요.");
return false; return false;
} }
$("input[name=searchStartDate]").val(start); $("input[name=searchStartDate]").val(start);
$("input[name=searchEndDate]").val(end); $("input[name=searchEndDate]").val(end);
postData["searchStartDate"] = start; postData["searchStartDate"] = start;
postData["searchEndDate"] = end; postData["searchEndDate"] = end;
@@ -197,14 +212,24 @@ $(document).ready(function() {
<tbody> <tbody>
<tr> <tr>
<th style="width:180px;"><%= localeMessage.getString("infConHstMan.date") %></th> <th style="width:180px;"><%= localeMessage.getString("infConHstMan.date") %></th>
<td> <td colspan="5">
<input type="text" name="searchStartYYYYMMDD" id="startDatepicker" readonly="readonly" value="" size="10" style="width:80px; border:1px solid #ebebec;"> <input type="text" name="searchStartYYYYMMDD" id="startDatepicker" readonly="readonly" value="" size="10" style="width:80px; border:1px solid #ebebec;">
~ <input type="text" name="searchStartTime" value="" size="8" style="width:70px; border:1px solid #ebebec;">
~
<input type="text" name="searchEndYYYYMMDD" value="" id="endDatepicker" size="10" readonly="readonly" style="width:80px; border:1px solid #ebebec;"> <input type="text" name="searchEndYYYYMMDD" value="" id="endDatepicker" size="10" readonly="readonly" style="width:80px; border:1px solid #ebebec;">
<input type="text" name="searchEndTime" value="" size="8" style="width:70px; border:1px solid #ebebec;">
<input type="hidden" name="searchStartDate" value="" style="width:0px;"> <input type="hidden" name="searchStartDate" value="" style="width:0px;">
<input type="hidden" name="searchEndDate" value="" style="width:0px;"> <input type="hidden" name="searchEndDate" value="" style="width:0px;">
</td> </td>
</tr> </tr>
<tr>
<th style="width:180px;"><%= localeMessage.getString("infConHstMan.instNm") %></th>
<td><input type="text" name="searchInstanceName" value="${param.searchInstanceName}"></td>
<th style="width:180px;"><%= localeMessage.getString("infConHstMan.eaiSvcCd") %></th>
<td><input type="text" name="searchApiName" value="${param.searchApiName}"></td>
<th style="width:180px;"><%= localeMessage.getString("infConHstMan.adpGrpNm") %></th>
<td><input type="text" name="searchAdapterGroupName" value="${param.searchAdapterGroupName}"></td>
</tr>
</tbody> </tbody>
</table> </table>
</form> </form>
@@ -88,7 +88,7 @@ $(document).ready(function() {
datatype:"json", datatype:"json",
mtype: 'POST', mtype: 'POST',
url: url, url: url,
postData : { cmd : 'LIST', searchGroupName: $('input[name=searchGroupName]').val()}, postData : { cmd : 'LIST', searchGroupName: $('input[name=searchGroupName]').val(), searchUseYn: $('select[name=searchUseYn]').val()},
colNames:['그룹 ID', colNames:['그룹 ID',
'그룹명', '그룹명',
'초당 임계치', '초당 임계치',
@@ -125,6 +125,7 @@ $(document).ready(function() {
url2 += '&menuId='+'${param.menuId}'; url2 += '&menuId='+'${param.menuId}';
//검색값 //검색값
url2 += '&searchGroupName='+$("input[name=searchGroupName]").val(); url2 += '&searchGroupName='+$("input[name=searchGroupName]").val();
url2 += '&searchUseYn='+$("select[name=searchUseYn]").val();
//key값 //key값
url2 += '&groupId='+groupId; url2 += '&groupId='+groupId;
goNav(url2); goNav(url2);
@@ -143,7 +144,7 @@ $(document).ready(function() {
resizeJqGridWidth('grid','content_middle','1000'); resizeJqGridWidth('grid','content_middle','1000');
$("#btn_search").click(function(){ $("#btn_search").click(function(){
$("#grid").setGridParam({ postData: { searchGroupName: $('input[name=searchGroupName]').val()}, page:1 }).trigger("reloadGrid"); $("#grid").setGridParam({ postData: { searchGroupName: $('input[name=searchGroupName]').val(), searchUseYn: $('select[name=searchUseYn]').val()}, page:1 }).trigger("reloadGrid");
}); });
$("#btn_new").click(function(){ $("#btn_new").click(function(){
var url2 = url_view; var url2 = url_view;
@@ -188,6 +189,16 @@ $(document).ready(function() {
<tr> <tr>
<th style="width:180px;">그룹명</th> <th style="width:180px;">그룹명</th>
<td><input type="text" name="searchGroupName" value="${param.searchGroupName}"></td> <td><input type="text" name="searchGroupName" value="${param.searchGroupName}"></td>
<th style="width:180px;">사용여부</th>
<td>
<div class="select-style">
<select name="searchUseYn">
<option value="">전체</option>
<option value="1">사용함</option>
<option value="0">사용안함</option>
</select>
</div>
</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
@@ -25,7 +25,7 @@ $(document).ready(function() {
datatype:"json", datatype:"json",
mtype: 'POST', mtype: 'POST',
url: url, url: url,
postData : { cmd : 'LIST', searchName: $('input[name=searchName]').val()}, postData : { cmd : 'LIST', searchName: $('input[name=searchName]').val(), searchUseYn: $('select[name=searchUseYn]').val()},
colNames:['<%= localeMessage.getString("infIfConMan.ifNm") %>', colNames:['<%= localeMessage.getString("infIfConMan.ifNm") %>',
'<%= localeMessage.getString("infIfConMan.ifDesc") %>', '<%= localeMessage.getString("infIfConMan.ifDesc") %>',
'<%= localeMessage.getString("infAdpConMan.thrPerSecond") %>', '<%= localeMessage.getString("infAdpConMan.thrPerSecond") %>',
@@ -62,6 +62,7 @@ $(document).ready(function() {
url2 += '&menuId='+'${param.menuId}'; url2 += '&menuId='+'${param.menuId}';
//검색값 //검색값
url2 += '&searchName='+$("input[name=searchName]").val(); url2 += '&searchName='+$("input[name=searchName]").val();
url2 += '&searchUseYn='+$("select[name=searchUseYn]").val();
//key값 //key값
url2 += '&name='+name; url2 += '&name='+name;
goNav(url2); goNav(url2);
@@ -80,7 +81,7 @@ $(document).ready(function() {
resizeJqGridWidth('grid','content_middle','1000'); resizeJqGridWidth('grid','content_middle','1000');
$("#btn_search").click(function(){ $("#btn_search").click(function(){
$("#grid").setGridParam({ postData: { searchName: $('input[name=searchName]').val()}, page:1 }).trigger("reloadGrid"); $("#grid").setGridParam({ postData: { searchName: $('input[name=searchName]').val(), searchUseYn: $('select[name=searchUseYn]').val()}, page:1 }).trigger("reloadGrid");
}); });
$("#btn_new").click(function(){ $("#btn_new").click(function(){
var url2 = url_view; var url2 = url_view;
@@ -126,6 +127,16 @@ $(document).ready(function() {
<tr> <tr>
<th style="width:180px;"><%= localeMessage.getString("infIfConMan.ifNm") %></th> <th style="width:180px;"><%= localeMessage.getString("infIfConMan.ifNm") %></th>
<td><input type="text" name="searchName" value="${param.searchName}"></td> <td><input type="text" name="searchName" value="${param.searchName}"></td>
<th style="width:180px;"><%= localeMessage.getString("infAdpConMan.useYn") %></th>
<td>
<div class="select-style">
<select name="searchUseYn">
<option value="">전체</option>
<option value="1">사용함</option>
<option value="0">사용안함</option>
</select>
</div>
</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
@@ -0,0 +1,258 @@
<%@ page language="java" contentType="text/html; charset=utf-8"%>
<%@ page import="java.io.*"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ include file="/jsp/common/include/localemessage.jsp" %>
<%
response.setHeader("Pragma", "No-cache");
response.setHeader("Cache-Control", "no-cache");
response.setHeader("Expires", "0");
%>
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=euc-kr">
<jsp:include page="/jsp/common/include/css.jsp"/>
<jsp:include page="/jsp/common/include/script.jsp"/>
<script language="javascript" >
var url = '<c:url value="/onl/transaction/apim/apiInterfaceMan.json"/>';
var url_view = '<c:url value="/onl/transaction/apim/apiInterfaceMan.view"/>';
var selectName = "searchEaiBzwkDstcd"; // selectBox Name
function processSelectedData() {
var grid = $("#grid");
var selectedRowIds = grid.jqGrid('getGridParam', 'selarrrow');
var selectedData = [];
for(var i = 0; i < selectedRowIds.length; i++) {
var rowData = grid.jqGrid('getRowData', selectedRowIds[i]);
selectedData.push({
bizCode: rowData.eaiBzwkDstcd, // CLINET
apiId: rowData.eaiSvcName,
apiDesc: rowData.eaiSvcDesc, // SCOPE-API
APIFULLPATH: rowData.apiFullPath,
BZWKSVCKEYNAME: rowData.bzwksvckeyname
});
}
if(selectedData.length === 0) {
alert("선택된 항목이 없습니다.");
return;
}
alert("선택한 " + selectedData.length + "건의 API를 추가합니다.");
window.returnValue = selectedData.length === 1 ? selectedData[0] : selectedData;
window.close();
}
function updateSelectionInfo(gridId) {
var grid = $(gridId || "#grid");
var selectedRows = grid.jqGrid('getGridParam', 'selarrrow');
$("#selected-count").text("총: " + selectedRows.length + " 건");
}
function init( callback) {
$.ajax({
type : "POST",
url:url,
dataType:"json",
data:{cmd: 'LIST_COMBO'},
success:function(json){
new makeOptions("BIZCODE","BIZNAME").setObj($("select[name=searchEaiBzwkDstcd]")).setNoValueInclude(true).setNoValue("","전체").setData(json.bizList).setFormat(codeName3OptionFormat).rendering();
setSearchable(selectName); // 콤보에 searchable 설정
if (typeof callback === 'function') {
callback();
}
},
error:function(e){
alert(e.responseText);
}
});
}
function detail(){
var postData = getSearchForJqgrid("cmd","LIST"); //jqgrid에서는 object 로
$("#grid").setGridParam({ url:url,postData: postData }).trigger("reloadGrid");
}
function search(){
var postData = getSearchForJqgrid("cmd","LIST"); //jqgrid에서는 object 로
$("#grid").setGridParam({ url:url,postData: postData ,page:1 }).trigger("reloadGrid");
}
function ioFormatter(cellvalue,options,rowObject){
var serviceType = sessionStorage["serviceType"];
if(cellvalue == "I"){
return "타발";
}else if(cellvalue =="O"){
return "당발";
}
}
function adapterNameShortFormatter(cellvalue,options,rowObject){
if(cellvalue == null || cellvalue == '')
return ''
return cellvalue.substring(1, 4);
}
function list(){
detail()
var gridPostData = getSearchForJqgrid("cmd","LIST"); //jqgrid에서는 object 로
// gridPostData.searchApiEnableYn = 'Y';
var urlParams = new URLSearchParams(window.location.search);
var selectedApiIds = urlParams.get("selectedApiIds");
$('#grid').jqGrid({
datatype : "json",
mtype : 'POST',
url : url,
postData : gridPostData,
colNames : [ '업무구분',
'<%= localeMessage.getString("eaiMessage.eaiSvcName")%>',
'<%= localeMessage.getString("eaiMessage.eaiSvcDesc")%>',
'API FULL PATH',
'업무서비스명',
'요청',
'응답',
'작성자',
'가상응답여부',
'SyncAsyncType',
],
colModel : [ { name : 'eaiBzwkDstcd' , align : 'center' , width:'40', sortable:false},
{ name : 'eaiSvcName' , align : 'left' , width:'100'},
{ name : 'eaiSvcDesc' , align : 'left' },
{ name : 'apiFullPath' , align : 'left' , width:'100'},
{ name : 'bzwksvckeyname' , align : 'left' , width:'100', hidden: true},
{ name : 'fromAdapter' , align : 'center' , width:'40', formatter:adapterNameShortFormatter },
{ name : 'toAdapter' , align : 'center' , width:'40', formatter:adapterNameShortFormatter },
{ name : 'author' , align : 'center' , width:'60' },
{ name : 'simYn' , align : 'center' , width:'40' },
{ name : 'syncAsyncType' , align : 'center' , width:'40', hidden: true},
],
jsonReader : {
repeatitems : false
},
pager : $('#pager'),
page : '${param.page}',
rowNum : '${rmsDefaultRowNum}',
autoheight : true,
height : $("#container").height(),
autowidth : true,
viewrecords : true,
multiselect: false,
multiboxonly: false,
rowList : eval('[${rmsDefaultRowList}]'),
loadComplete:function (d){
var $grid = $(this);
if(selectedApiIds) {
const selectedIds = selectedApiIds.split(',');
$.each($grid.getDataIDs(), function(_, id) {
var rowData = $grid.getRowData(id);
if(selectedIds.includes(rowData.eaiSvcName)) {
$grid.jqGrid('setSelection', id, true);
}
});
}
var colModel = $(this).getGridParam("colModel");
for(var i = 0 ; i< colModel.length; i++){
$(this).setColProp(colModel[i].name, {sortable : false});
}
updateSelectionInfo("#grid");
},
onSelectRow: function(rowid, status, e) {
updateSelectionInfo("#grid");
},
onSelectAll: function(rowids, status) {
updateSelectionInfo("#grid");
},
ondblClickRow : function(rowId) {
const rowData = $(this).getRowData(rowId);
const returnValue = {
bizCode: rowData.eaiBzwkDstcd,
apiId: rowData.eaiSvcName,
apiDesc: rowData.eaiSvcDesc
};
//alert("선택한 API를 추가합니다.\nAPI ID: " + rowData.eaiSvcName);
window.returnValue = returnValue;
window.close();
}
});
}
$(document).ready(function() {
init(list);
resizeJqGridWidth('grid','content_middle','1000');
// 업무구분명 선택 시 자동 검색
$("select[name=searchEaiBzwkDstcd]").change(function() {
search();
});
$("#btn_search").click(function(){
search();
});
$("input[name^=search]").keydown(function(key){
if (key.keyCode == 13){
$("#btn_search").click();
}
});
buttonControl();
$("#btn_select").click(function(){
processSelectedData();
});
$("#btn_close").click(function () {
window.close();
});
});
</script>
</head>
<body>
<div>
<div class="content_middle" id="content_middle" style="margin-top: 0px">
<div class="search_wrap">
<button type="button" class="cssbtn" id="btn_search" level="R" ><i class="material-icons">search</i> <%= localeMessage.getString("button.search") %></button>
<button type="button" class="cssbtn" id="btn_select" level="R" ><i class="material-icons">check</i> <%= localeMessage.getString("button.check") %></button>
<button type="button" class="cssbtn" id="btn_close" level="R" status="DETAIL"><i class="material-icons">close</i> <%= localeMessage.getString("button.close") %></button>
</div>
<div class="title" id="title" >${rmsMenuName}</div>
<!-- 선택 정보 표시 영역 추가 -->
<div style="margin-bottom: 5px;">
<span id="selected-count" style="color: #666; font-size: 12px;"></span>
</div>
<table class="search_condition" cellspacing=0;>
<tbody>
<tr>
<th style="width:180px;">업무구분명</th>
<td>
<select name="searchEaiBzwkDstcd" value="${param.searchEaiBzwkDstcd}">
</select>
</td>
<th style="width:180px;"><%= localeMessage.getString("eaiMessage.eaiSvcName")%></th>
<td>
<input type="text" name="searchEaiSvcName" value="${param.searchEaiSvcName}">
</td>
</tr>
<tr>
<th style="width:180px;"><%= localeMessage.getString("eaiMessage.eaiSvcDesc")%></th>
<td>
<input type="text" name="searchEaiSvcDesc" value="${param.searchEaiSvcDesc}">
</td>
<th style="width:180px;">API FULL PATH</th>
<td>
<input type="text" name="searchApiFullPath" value="${param.searchApiFullPath}">
</td>
</tr>
</tbody>
</table>
<table id="grid" ></table>
<div id="pager"></div>
</div><!-- end content_middle -->
</div><!-- end right_box -->
</body>
</html>
@@ -1947,8 +1947,8 @@
var key = ""; var key = "";
var args = new Object(); var args = new Object();
args['eaiSvcName'] = $('input[name=eaiSvcName]').val(); args['eaiSvcName'] = $('input[name=eaiSvcName]').val();
var url='<c:url value="/onl/transaction/extnl/interfaceMan.view"/>'; var url=url_view; //'<c:url value="/onl/transaction/extnl/interfaceMan.view"/>';
url = url + "?cmd=POPUP"; url = url + "?cmd=API_POPUP";
var ret = showModal(url,args,1020,630, function(arg){ var ret = showModal(url,args,1020,630, function(arg){
var args = null; var args = null;
if(arg == null || arg == undefined ) {//chrome if(arg == null || arg == undefined ) {//chrome
@@ -1962,11 +1962,11 @@
var ret = args.returnValue; var ret = args.returnValue;
console.log("ret",ret); console.log("ret",ret);
key = ret['key']; key = ret['apiId'];
$("input[name=eaiSvcName]").val(key); $("input[name=eaiSvcName]").val(key);
$("input[name=eaiSvcDesc]").val(ret['eaiSvcDesc']); $("input[name=eaiSvcDesc]").val(ret['apiDesc']);
bzwkDstCd = ret['eaiBzwkDstCd']; bzwkDstCd = ret['bizCode'];
$("input[name=eaiSvcName]").change(); $("input[name=eaiSvcName]").change();
}); });
@@ -19,7 +19,8 @@
<jsp:include page="/jsp/common/include/css.jsp"/> <jsp:include page="/jsp/common/include/css.jsp"/>
<jsp:include page="/jsp/common/include/script.jsp"/> <jsp:include page="/jsp/common/include/script.jsp"/>
<script language="javascript" > <script language="javascript" >
var url_view = '<c:url value="/onl/admin/rule/transform2/transform2Man.view" />';
var $ = jQuery.noConflict(); var $ = jQuery.noConflict();
var bzwkDstCd = ""; var bzwkDstCd = "";
@@ -81,8 +82,9 @@ $(document).ready(function() {
var key = ""; var key = "";
var args = new Object(); var args = new Object();
args['eaiSvcName'] = $('input[name=eaiSvcName]').val(); args['eaiSvcName'] = $('input[name=eaiSvcName]').val();
var url='<c:url value="/onl/transaction/extnl/interfaceMan.view"/>'; var url=url_view; //'<c:url value="/onl/transaction/extnl/interfaceMan.view"/>';
url = url + "?cmd=POPUP"; url = url + "?cmd=API_POPUP";
console.log('[new]', url);
var ret = showModal(url,args,1020,630, function(arg){ var ret = showModal(url,args,1020,630, function(arg){
var args = null; var args = null;
if(arg == null || arg == undefined ) {//chrome if(arg == null || arg == undefined ) {//chrome
@@ -96,11 +98,11 @@ $(document).ready(function() {
var ret = args.returnValue; var ret = args.returnValue;
console.log("ret",ret); console.log("ret",ret);
key = ret['key']; key = ret['apiId'];
$("input[name=eaiSvcName]").val(key); $("input[name=eaiSvcName]").val(key);
$("input[name=eaiSvcDesc]").val(ret['eaiSvcDesc']); $("input[name=eaiSvcDesc]").val(ret['apiDesc']);
bzwkDstCd = ret['eaiBzwkDstCd']; bzwkDstCd = ret['bizCode'];
$("input[name=eaiSvcName]").change(); $("input[name=eaiSvcName]").change();
//$("select[name=eaiSevrDstcd]").val(ret['eaiSevrDstcd']); //$("select[name=eaiSevrDstcd]").val(ret['eaiSevrDstcd']);
@@ -66,22 +66,27 @@
}, },
tooltip: { tooltip: {
trigger: 'item', trigger: 'item',
formatter: '{b}: {c} ({d}%)' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString() + ' (' + params.percent + '%)';
}
}, },
legend: { legend: {
orient: 'horizontal', orient: 'vertical',
bottom: 10, right: 30,
top: 'middle',
data: ['성공', 'Timeout', '시스템오류'] data: ['성공', 'Timeout', '시스템오류']
}, },
series: [{ series: [{
name: '총건수', name: '총건수',
type: 'pie', type: 'pie',
radius: ['40%', '70%'], radius: ['38%', '65%'],
center: ['50%', '50%'], center: ['44%', '55%'],
avoidLabelOverlap: true, avoidLabelOverlap: true,
label: { label: {
show: true, show: true,
formatter: '{b}: {c}' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString();
}
}, },
emphasis: { emphasis: {
label: { label: {
@@ -98,18 +103,6 @@
{ value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } }, { value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } },
{ value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } } { value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } }
] ]
}],
graphic: [{
type: 'text',
left: 'center',
top: 'center',
style: {
text: '0',
textAlign: 'center',
fill: '#333',
fontSize: 24,
fontWeight: 'bold'
}
}] }]
}; };
@@ -119,7 +112,7 @@
// 호출량 차트 // 호출량 차트
var callOption = { var callOption = {
title: { text: '호출량 추이', left: 'center', textStyle: { fontSize: 14 } }, title: { text: '호출량 추이', left: 'center', top: 10, textStyle: { fontSize: 14 } },
tooltip: { tooltip: {
trigger: 'axis', trigger: 'axis',
axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } } axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } }
@@ -191,13 +184,9 @@
{ value: totalTimeout, name: 'Timeout' }, { value: totalTimeout, name: 'Timeout' },
{ value: totalSystemErr, name: '시스템오류' } { value: totalSystemErr, name: '시스템오류' }
] ]
}],
graphic: [{
style: {
text: grandTotal.toLocaleString()
}
}] }]
}); });
$("#totalDonutCenterText").text(grandTotal.toLocaleString());
// 호출량 차트 업데이트 // 호출량 차트 업데이트
@@ -455,6 +444,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -501,6 +493,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -587,10 +582,18 @@
</button> </button>
</div> </div>
<div class="title" id="title">API 일별 통계</div> <div class="title" id="title">API 일별 통계</div>
<table class="search_condition" cellspacing="0"> <table class="search_condition" cellspacing="0" style="table-layout:fixed;">
<colgroup>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
</colgroup>
<tbody> <tbody>
<tr> <tr>
<th style="width:100px;">조회기간</th> <th>조회기간</th>
<td colspan="5"> <td colspan="5">
<input type="text" name="searchStartDateTime" value="${param.searchStartDateTime}" style="width:100px;"> <input type="text" name="searchStartDateTime" value="${param.searchStartDateTime}" style="width:100px;">
~ ~
@@ -599,29 +602,29 @@
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">API명</th> <th>API명</th>
<td> <td>
<input type="text" name="searchApiName" value="${param.searchApiName}"> <input type="text" name="searchApiName" value="${param.searchApiName}">
</td> </td>
<th style="width:100px;">업무구분</th> <th>업무구분</th>
<td> <td>
<input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}"> <input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}">
</td> </td>
<th style="width:100px;">인스턴스</th> <th>인스턴스</th>
<td> <td>
<input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}"> <input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}">
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">클라이언트ID</th> <th>클라이언트ID</th>
<td> <td>
<input type="text" name="searchClientId" value="${param.searchClientId}"> <input type="text" name="searchClientId" value="${param.searchClientId}">
</td> </td>
<th style="width:100px;">Inbound Adapter</th> <th>Inbound Adapter</th>
<td> <td>
<input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}"> <input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}">
</td> </td>
<th style="width:100px;">Outbound Adapter</th> <th>Outbound Adapter</th>
<td> <td>
<input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}"> <input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}">
</td> </td>
@@ -630,7 +633,10 @@
</table> </table>
<!-- 도넛 차트 (상단 50%씩) --> <!-- 도넛 차트 (상단 50%씩) -->
<div class="chart-container"> <div class="chart-container">
<div id="totalDonutChart" class="chart"></div> <div class="chart" style="position:relative; padding:0;">
<div id="totalDonutChart" style="width:100%; height:100%;"></div>
<div id="totalDonutCenterText" style="position:absolute; left:44.5%; top:55%; transform:translate(-50%,-50%); font-size:24px; font-weight:bold; color:#333; pointer-events:none; z-index:10;">0</div>
</div>
<div id="callChart" class="chart"></div> <div id="callChart" class="chart"></div>
</div> </div>
@@ -67,22 +67,27 @@
}, },
tooltip: { tooltip: {
trigger: 'item', trigger: 'item',
formatter: '{b}: {c} ({d}%)' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString() + ' (' + params.percent + '%)';
}
}, },
legend: { legend: {
orient: 'horizontal', orient: 'vertical',
bottom: 10, right: 30,
top: 'middle',
data: ['성공', 'Timeout', '시스템오류'] data: ['성공', 'Timeout', '시스템오류']
}, },
series: [{ series: [{
name: '총건수', name: '총건수',
type: 'pie', type: 'pie',
radius: ['40%', '70%'], radius: ['38%', '65%'],
center: ['50%', '50%'], center: ['44%', '55%'],
avoidLabelOverlap: true, avoidLabelOverlap: true,
label: { label: {
show: true, show: true,
formatter: '{b}: {c}' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString();
}
}, },
emphasis: { emphasis: {
label: { label: {
@@ -99,18 +104,6 @@
{ value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } }, { value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } },
{ value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } } { value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } }
] ]
}],
graphic: [{
type: 'text',
left: 'center',
top: 'center',
style: {
text: '0',
textAlign: 'center',
fill: '#333',
fontSize: 24,
fontWeight: 'bold'
}
}] }]
}; };
@@ -120,7 +113,7 @@
// 호출량 차트 // 호출량 차트
var callOption = { var callOption = {
title: { text: '호출량 추이', left: 'center', textStyle: { fontSize: 14 } }, title: { text: '호출량 추이', left: 'center', top: 10, textStyle: { fontSize: 14 } },
tooltip: { tooltip: {
trigger: 'axis', trigger: 'axis',
axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } } axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } }
@@ -227,13 +220,9 @@
{ value: totalTimeout, name: 'Timeout' }, { value: totalTimeout, name: 'Timeout' },
{ value: totalSystemErr, name: '시스템오류' } { value: totalSystemErr, name: '시스템오류' }
] ]
}],
graphic: [{
style: {
text: grandTotal.toLocaleString()
}
}] }]
}); });
$("#totalDonutCenterText").text(grandTotal.toLocaleString());
// 호출량 차트 업데이트 // 호출량 차트 업데이트
@@ -457,6 +446,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -503,6 +495,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -567,41 +562,47 @@
</button> </button>
</div> </div>
<div class="title" id="title">API 시간별 통계</div> <div class="title" id="title">API 시간별 통계</div>
<table class="search_condition" cellspacing="0"> <table class="search_condition" cellspacing="0" style="table-layout:fixed;">
<colgroup>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
</colgroup>
<tbody> <tbody>
<tr> <tr>
<th style="width:100px;">조회일자</th> <th>조회일자</th>
<td colspan="3"> <td colspan="5">
<input type="text" name="searchDate" value="${param.searchDate}" style="width:100px;"> <input type="text" name="searchDate" value="${param.searchDate}" style="width:100px;">
<span style="color:#888; font-size:12px; margin-left:10px;">(선택일 00시 ~ 23시 조회)</span> <span style="color:#888; font-size:12px; margin-left:10px;">(선택일 00시 ~ 23시 조회)</span>
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">API명</th> <th>API명</th>
<td> <td>
<input type="text" name="searchApiName" value="${param.searchApiName}"> <input type="text" name="searchApiName" value="${param.searchApiName}">
</td> </td>
<th style="width:100px;">인스턴스</th> <th>업무구분</th>
<td>
<input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}">
</td>
<th>인스턴스</th>
<td> <td>
<input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}"> <input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}">
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">업무구분</th> <th>클라이언트ID</th>
<td>
<input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}">
</td>
<th style="width:100px;">클라이언트ID</th>
<td> <td>
<input type="text" name="searchClientId" value="${param.searchClientId}"> <input type="text" name="searchClientId" value="${param.searchClientId}">
</td> </td>
</tr> <th>Inbound Adapter</th>
<tr>
<th style="width:100px;">Inbound Adapter</th>
<td> <td>
<input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}"> <input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}">
</td> </td>
<th style="width:100px;">Outbound Adapter</th> <th>Outbound Adapter</th>
<td> <td>
<input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}"> <input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}">
</td> </td>
@@ -610,7 +611,10 @@
</table> </table>
<!-- 도넛 차트 (상단 50%씩) --> <!-- 도넛 차트 (상단 50%씩) -->
<div class="chart-container"> <div class="chart-container">
<div id="totalDonutChart" class="chart"></div> <div class="chart" style="position:relative; padding:0;">
<div id="totalDonutChart" style="width:100%; height:100%;"></div>
<div id="totalDonutCenterText" style="position:absolute; left:44.5%; top:55%; transform:translate(-50%,-50%); font-size:24px; font-weight:bold; color:#333; pointer-events:none; z-index:10;">0</div>
</div>
<div id="callChart" class="chart"></div> <div id="callChart" class="chart"></div>
</div> </div>
@@ -59,22 +59,27 @@
}, },
tooltip: { tooltip: {
trigger: 'item', trigger: 'item',
formatter: '{b}: {c} ({d}%)' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString() + ' (' + params.percent + '%)';
}
}, },
legend: { legend: {
orient: 'horizontal', orient: 'vertical',
bottom: 10, right: 30,
top: 'middle',
data: ['성공', 'Timeout', '시스템오류'] data: ['성공', 'Timeout', '시스템오류']
}, },
series: [{ series: [{
name: '총건수', name: '총건수',
type: 'pie', type: 'pie',
radius: ['40%', '70%'], radius: ['38%', '65%'],
center: ['50%', '50%'], center: ['44%', '55%'],
avoidLabelOverlap: true, avoidLabelOverlap: true,
label: { label: {
show: true, show: true,
formatter: '{b}: {c}' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString();
}
}, },
emphasis: { emphasis: {
label: { label: {
@@ -91,18 +96,6 @@
{ value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } }, { value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } },
{ value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } } { value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } }
] ]
}],
graphic: [{
type: 'text',
left: 'center',
top: 'center',
style: {
text: '0',
textAlign: 'center',
fill: '#333',
fontSize: 24,
fontWeight: 'bold'
}
}] }]
}; };
@@ -111,8 +104,8 @@
// 호출량 차트 // 호출량 차트
var callOption = { var callOption = {
title: { text: '호출량 추이', left: 'center', textStyle: { fontSize: 14 } }, title: { text: '호출량 추이', left: 'center', top: 10, textStyle: { fontSize: 14 } },
tooltip: { tooltip: {
trigger: 'axis', trigger: 'axis',
axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } } axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } }
@@ -189,13 +182,9 @@
{ value: totalTimeout, name: 'Timeout' }, { value: totalTimeout, name: 'Timeout' },
{ value: totalSystemErr, name: '시스템오류' } { value: totalSystemErr, name: '시스템오류' }
] ]
}],
graphic: [{
style: {
text: grandTotal.toLocaleString()
}
}] }]
}); });
$("#totalDonutCenterText").text(grandTotal.toLocaleString());
// 호출량 차트 업데이트 // 호출량 차트 업데이트
@@ -470,6 +459,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -516,6 +508,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -619,7 +614,10 @@
</table> </table>
<!-- 도넛 차트 (상단 50%씩) --> <!-- 도넛 차트 (상단 50%씩) -->
<div class="chart-container"> <div class="chart-container">
<div id="totalDonutChart" class="chart"></div> <div class="chart" style="position:relative; padding:0;">
<div id="totalDonutChart" style="width:100%; height:100%;"></div>
<div id="totalDonutCenterText" style="position:absolute; left:44.5%; top:55%; transform:translate(-50%,-50%); font-size:24px; font-weight:bold; color:#333; pointer-events:none; z-index:10;">0</div>
</div>
<div id="callChart" class="chart"></div> <div id="callChart" class="chart"></div>
</div> </div>
@@ -66,22 +66,27 @@
}, },
tooltip: { tooltip: {
trigger: 'item', trigger: 'item',
formatter: '{b}: {c} ({d}%)' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString() + ' (' + params.percent + '%)';
}
}, },
legend: { legend: {
orient: 'horizontal', orient: 'vertical',
bottom: 10, right: 30,
top: 'middle',
data: ['성공', 'Timeout', '시스템오류'] data: ['성공', 'Timeout', '시스템오류']
}, },
series: [{ series: [{
name: '총건수', name: '총건수',
type: 'pie', type: 'pie',
radius: ['40%', '70%'], radius: ['38%', '65%'],
center: ['50%', '50%'], center: ['44%', '55%'],
avoidLabelOverlap: true, avoidLabelOverlap: true,
label: { label: {
show: true, show: true,
formatter: '{b}: {c}' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString();
}
}, },
emphasis: { emphasis: {
label: { label: {
@@ -98,18 +103,6 @@
{ value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } }, { value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } },
{ value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } } { value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } }
] ]
}],
graphic: [{
type: 'text',
left: 'center',
top: 'center',
style: {
text: '0',
textAlign: 'center',
fill: '#333',
fontSize: 24,
fontWeight: 'bold'
}
}] }]
}; };
@@ -119,7 +112,7 @@
// 호출량 차트 // 호출량 차트
var callOption = { var callOption = {
title: { text: '호출량 추이', left: 'center', textStyle: { fontSize: 14 } }, title: { text: '호출량 추이', left: 'center', top: 10, textStyle: { fontSize: 14 } },
tooltip: { tooltip: {
trigger: 'axis', trigger: 'axis',
axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } } axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } }
@@ -189,13 +182,9 @@
{ value: totalTimeout, name: 'Timeout' }, { value: totalTimeout, name: 'Timeout' },
{ value: totalSystemErr, name: '시스템오류' } { value: totalSystemErr, name: '시스템오류' }
] ]
}],
graphic: [{
style: {
text: grandTotal.toLocaleString()
}
}] }]
}); });
$("#totalDonutCenterText").text(grandTotal.toLocaleString());
@@ -460,6 +449,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -506,6 +498,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -578,11 +573,19 @@
</button> </button>
</div> </div>
<div class="title" id="title">API 월별 통계</div> <div class="title" id="title">API 월별 통계</div>
<table class="search_condition" cellspacing="0"> <table class="search_condition" cellspacing="0" style="table-layout:fixed;">
<colgroup>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
</colgroup>
<tbody> <tbody>
<tr> <tr>
<th style="width:100px;">조회기간</th> <th>조회기간</th>
<td colspan="3"> <td colspan="5">
<input type="text" name="searchStartDateTime" value="${param.searchStartDateTime}" style="width:100px;" placeholder="YYYY-MM"> <input type="text" name="searchStartDateTime" value="${param.searchStartDateTime}" style="width:100px;" placeholder="YYYY-MM">
~ ~
<input type="text" name="searchEndDateTime" value="${param.searchEndDateTime}" style="width:100px;" placeholder="YYYY-MM"> <input type="text" name="searchEndDateTime" value="${param.searchEndDateTime}" style="width:100px;" placeholder="YYYY-MM">
@@ -590,31 +593,29 @@
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">API명</th> <th>API명</th>
<td> <td>
<input type="text" name="searchApiName" value="${param.searchApiName}"> <input type="text" name="searchApiName" value="${param.searchApiName}">
</td> </td>
<th style="width:100px;">인스턴스</th> <th>업무구분</th>
<td>
<input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}">
</td>
<th>인스턴스</th>
<td> <td>
<input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}"> <input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}">
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">업무구분</th> <th>클라이언트ID</th>
<td>
<input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}">
</td>
<th style="width:100px;">클라이언트ID</th>
<td> <td>
<input type="text" name="searchClientId" value="${param.searchClientId}"> <input type="text" name="searchClientId" value="${param.searchClientId}">
</td> </td>
</tr> <th>Inbound Adapter</th>
<tr>
<th style="width:100px;">Inbound Adapter</th>
<td> <td>
<input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}"> <input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}">
</td> </td>
<th style="width:100px;">Outbound Adapter</th> <th>Outbound Adapter</th>
<td> <td>
<input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}"> <input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}">
</td> </td>
@@ -623,7 +624,10 @@
</table> </table>
<!-- 도넛 차트 (상단 50%씩) --> <!-- 도넛 차트 (상단 50%씩) -->
<div class="chart-container"> <div class="chart-container">
<div id="totalDonutChart" class="chart"></div> <div class="chart" style="position:relative; padding:0;">
<div id="totalDonutChart" style="width:100%; height:100%;"></div>
<div id="totalDonutCenterText" style="position:absolute; left:44.5%; top:55%; transform:translate(-50%,-50%); font-size:24px; font-weight:bold; color:#333; pointer-events:none; z-index:10;">0</div>
</div>
<div id="callChart" class="chart"></div> <div id="callChart" class="chart"></div>
</div> </div>
@@ -66,22 +66,27 @@
}, },
tooltip: { tooltip: {
trigger: 'item', trigger: 'item',
formatter: '{b}: {c} ({d}%)' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString() + ' (' + params.percent + '%)';
}
}, },
legend: { legend: {
orient: 'horizontal', orient: 'vertical',
bottom: 10, right: 30,
top: 'middle',
data: ['성공', 'Timeout', '시스템오류'] data: ['성공', 'Timeout', '시스템오류']
}, },
series: [{ series: [{
name: '총건수', name: '총건수',
type: 'pie', type: 'pie',
radius: ['40%', '70%'], radius: ['38%', '65%'],
center: ['50%', '50%'], center: ['44%', '55%'],
avoidLabelOverlap: true, avoidLabelOverlap: true,
label: { label: {
show: true, show: true,
formatter: '{b}: {c}' formatter: function (params) {
return params.name + ': ' + params.value.toLocaleString();
}
}, },
emphasis: { emphasis: {
label: { label: {
@@ -98,18 +103,6 @@
{ value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } }, { value: 0, name: 'Timeout', itemStyle: { color: '#FAC858' } },
{ value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } } { value: 0, name: '시스템오류', itemStyle: { color: '#EE6666' } }
] ]
}],
graphic: [{
type: 'text',
left: 'center',
top: 'center',
style: {
text: '0',
textAlign: 'center',
fill: '#333',
fontSize: 24,
fontWeight: 'bold'
}
}] }]
}; };
@@ -119,7 +112,7 @@
// 호출량 차트 // 호출량 차트
var callOption = { var callOption = {
title: { text: '호출량 추이', left: 'center', textStyle: { fontSize: 14 } }, title: { text: '호출량 추이', left: 'center', top: 10, textStyle: { fontSize: 14 } },
tooltip: { tooltip: {
trigger: 'axis', trigger: 'axis',
axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } } axisPointer: { type: 'cross', label: { backgroundColor: '#6a7985' } }
@@ -191,13 +184,9 @@
{ value: totalTimeout, name: 'Timeout' }, { value: totalTimeout, name: 'Timeout' },
{ value: totalSystemErr, name: '시스템오류' } { value: totalSystemErr, name: '시스템오류' }
] ]
}],
graphic: [{
style: {
text: grandTotal.toLocaleString()
}
}] }]
}); });
$("#totalDonutCenterText").text(grandTotal.toLocaleString());
@@ -436,6 +425,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -482,6 +474,9 @@
for (var i = 0; i < colModel.length; i++) { for (var i = 0; i < colModel.length; i++) {
$(this).setColProp(colModel[i].name, { sortable: false }); $(this).setColProp(colModel[i].name, { sortable: false });
} }
// 조회(reloadGrid) 시 컬럼 폭이 고정폭(shrinkToFit:false)으로 남아
// 실제 컨테이너 폭과 어긋나 가로 스크롤이 생기는 것을 방지
$(this).jqGrid('setGridWidth', $('#content_middle').width(), true);
} }
}); });
} }
@@ -549,42 +544,48 @@
</button> </button>
</div> </div>
<div class="title" id="title">API 연간 통계</div> <div class="title" id="title">API 연간 통계</div>
<table class="search_condition" cellspacing="0"> <table class="search_condition" cellspacing="0" style="table-layout:fixed;">
<colgroup>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
<col style="width:150px;">
<col>
</colgroup>
<tbody> <tbody>
<tr> <tr>
<th style="width:100px;">조회기간</th> <th>조회기간</th>
<td colspan="3"> <td colspan="5">
<input type="text" name="searchStartDateTime" value="${param.searchStartDateTime}" style="width:100px;" placeholder="YYYY"> <input type="text" name="searchStartDateTime" value="${param.searchStartDateTime}" style="width:100px;" placeholder="YYYY">
~ ~
<input type="text" name="searchEndDateTime" value="${param.searchEndDateTime}" style="width:100px;" placeholder="YYYY"> <input type="text" name="searchEndDateTime" value="${param.searchEndDateTime}" style="width:100px;" placeholder="YYYY">
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">API명</th> <th>API명</th>
<td> <td>
<input type="text" name="searchApiName" value="${param.searchApiName}"> <input type="text" name="searchApiName" value="${param.searchApiName}">
</td> </td>
<th style="width:100px;">인스턴스</th> <th>업무구분</th>
<td>
<input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}">
</td>
<th>인스턴스</th>
<td> <td>
<input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}"> <input type="text" name="searchGwInstanceId" value="${param.searchGwInstanceId}">
</td> </td>
</tr> </tr>
<tr> <tr>
<th style="width:100px;">업무구분</th> <th>클라이언트ID</th>
<td>
<input type="text" name="searchBizDivCode" value="${param.searchBizDivCode}">
</td>
<th style="width:100px;">클라이언트ID</th>
<td> <td>
<input type="text" name="searchClientId" value="${param.searchClientId}"> <input type="text" name="searchClientId" value="${param.searchClientId}">
</td> </td>
</tr> <th>Inbound Adapter</th>
<tr>
<th style="width:100px;">Inbound Adapter</th>
<td> <td>
<input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}"> <input type="text" name="searchInboundAdapter" value="${param.searchInboundAdapter}">
</td> </td>
<th style="width:100px;">Outbound Adapter</th> <th>Outbound Adapter</th>
<td> <td>
<input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}"> <input type="text" name="searchOutboundAdapter" value="${param.searchOutboundAdapter}">
</td> </td>
@@ -593,7 +594,10 @@
</table> </table>
<!-- 도넛 차트 (상단 50%씩) --> <!-- 도넛 차트 (상단 50%씩) -->
<div class="chart-container"> <div class="chart-container">
<div id="totalDonutChart" class="chart"></div> <div class="chart" style="position:relative; padding:0;">
<div id="totalDonutChart" style="width:100%; height:100%;"></div>
<div id="totalDonutCenterText" style="position:absolute; left:44.5%; top:55%; transform:translate(-50%,-50%); font-size:24px; font-weight:bold; color:#333; pointer-events:none; z-index:10;">0</div>
</div>
<div id="callChart" class="chart"></div> <div id="callChart" class="chart"></div>
</div> </div>
@@ -77,7 +77,10 @@
display: inline-block; display: inline-block;
vertical-align: middle; vertical-align: middle;
} }
/* iframe 모달(showModal) 콘텐츠 패딩 제거 — iframe 이 다이얼로그 폭을 최대한 사용해 내부 가로스크롤 방지 */
.ui-dialog .ui-dialog-content { padding: 0 !important; }
</style> </style>
<script language="javascript" > <script language="javascript" >
var isDetail = false; var isDetail = false;
@@ -1012,7 +1015,12 @@
window.open(urlAddServiceType(baseUrl + '&menuId=' + encodeURIComponent(getMenuId())), '_blank'); window.open(urlAddServiceType(baseUrl + '&menuId=' + encodeURIComponent(getMenuId())), '_blank');
} else { } else {
// 기본: 모달 + iframe. showModal 이 serviceType/menuId/pop 을 자동 부착. // 기본: 모달 + iframe. showModal 이 serviceType/menuId/pop 을 자동 부착.
showModal(baseUrl, { title: 'OpenAPI Spec' }, 1600, 880); // 콘텐츠 고정폭 1600 + 다이얼로그 chrome(패딩/보더 ~40px) 때문에 iframe 내부폭이 1600 미만이면 가로스크롤 발생.
// 뷰포트 내에서 최대한 크게 열어(캡 1720) iframe 내부폭이 1600 이상 확보되게 한다.
var vw = $(window).width(), vh = $(window).height();
var modalW = Math.min(vw - 12, 1720);
var modalH = Math.min(vh - 20, 900);
showModal(baseUrl, { title: 'OpenAPI Spec' }, modalW, modalH);
} }
} }
@@ -1537,9 +1545,9 @@
<button type="button" class="cssbtn" id="btn_delete" level="W" status="DETAIL"><i class="material-icons">delete</i> <%= localeMessage.getString("button.delete") %></button> <button type="button" class="cssbtn" id="btn_delete" level="W" status="DETAIL"><i class="material-icons">delete</i> <%= localeMessage.getString("button.delete") %></button>
<button type="button" class="cssbtn" id="btn_modify" level="R" status="DETAIL,NEW"><i class="material-icons">save</i> <%= localeMessage.getString("button.modify") %></button> <button type="button" class="cssbtn" id="btn_modify" level="R" status="DETAIL,NEW"><i class="material-icons">save</i> <%= localeMessage.getString("button.modify") %></button>
<!-- v1: 기존 API 스펙 (모달) — 기능 비교용 복원 --> <!-- v1: 기존 API 스펙 (모달) — 기능 비교용 복원 -->
<button type="button" class="cssbtn" id="btn_api_spec" level="R" status="DETAIL,NEW"><i class="material-icons">description</i> API 스펙</button> <button type="button" class="cssbtn" id="btn_api_spec" level="R" status="DETAIL"><i class="material-icons">description</i> API 스펙(삭제예정)</button>
<!-- v2: 신규 OpenAPI Spec (새 탭) --> <!-- v2: 신규 OpenAPI Spec (새 탭) -->
<button type="button" class="cssbtn" id="btn_openapi_spec" level="R" status="DETAIL,NEW"><i class="material-icons">api</i> OpenAPI Spec</button> <button type="button" class="cssbtn" id="btn_openapi_spec" level="R" status="DETAIL"><i class="material-icons">api</i> OpenAPI Spec</button>
<button type="button" class="cssbtn" id="btn_previous" level="R" status="DETAIL,NEW"><i class="material-icons">arrow_back</i> <%= localeMessage.getString("button.previous") %></button> <button type="button" class="cssbtn" id="btn_previous" level="R" status="DETAIL,NEW"><i class="material-icons">arrow_back</i> <%= localeMessage.getString("button.previous") %></button>
</div> </div>
<div class="title" id="title" style="font-size:1.4em">${rmsMenuName}</div> <div class="title" id="title" style="font-size:1.4em">${rmsMenuName}</div>
+5 -10
View File
@@ -4,7 +4,6 @@ plugins {
id 'eclipse-wtp' id 'eclipse-wtp'
id 'idea' id 'idea'
id 'war' id 'war'
id 'com.diffplug.eclipse.apt' version '3.41.1'
} }
group 'com.eactive' group 'com.eactive'
@@ -49,10 +48,6 @@ compileJava {
options.encoding = 'UTF-8' options.encoding = 'UTF-8'
options.compilerArgs = ['-parameters'] options.compilerArgs = ['-parameters']
options.generatedSourceOutputDirectory = project.file(generatedJavaDir) options.generatedSourceOutputDirectory = project.file(generatedJavaDir)
aptOptions {
processorArgs = [ 'querydsl.generatedAnnotationClass' : 'com.querydsl.core.annotations.Generated' ]
}
} }
war { war {
@@ -257,11 +252,11 @@ eclipse {
} }
synchronizationTasks settingEclipseEncoding, initDirs synchronizationTasks settingEclipseEncoding, initDirs
jdt { jdt {
apt { // apt {
// generated 된 패스 경로를 .setting/org.eclipse.jdt.apt.core.prefs 의 org.eclipse.jdt.apt.genSrcDir에 적용한다. // // generated 된 패스 경로를 .setting/org.eclipse.jdt.apt.core.prefs 의 org.eclipse.jdt.apt.genSrcDir에 적용한다.
// project > properties > Java Compiler > Annoation Processing 화면에서 확인 가능하다. // // project > properties > Java Compiler > Annoation Processing 화면에서 확인 가능하다.
genSrcDir = file(generatedJavaDir) // genSrcDir = file(generatedJavaDir)
} // }
} }
project { project {
if (!natures.contains('org.eclipse.buildship.core.gradleprojectnature')) { if (!natures.contains('org.eclipse.buildship.core.gradleprojectnature')) {
@@ -36,7 +36,7 @@ class MonitoringContextImpl implements MonitoringContext {
@Autowired @Autowired
private MonitoringContextDAO monitoringContextDAO; private MonitoringContextDAO monitoringContextDAO;
private Properties properties = null; private Properties properties = new Properties();
private String instancePropertyGroupName; private String instancePropertyGroupName;
@@ -73,7 +73,10 @@ class MonitoringContextImpl implements MonitoringContext {
String hostIp = InetAddress.getLocalHost().getHostAddress(); String hostIp = InetAddress.getLocalHost().getHostAddress();
this.instancePropertyGroupName = String this.instancePropertyGroupName = String
.format(MonitoringPropertyGroupService.MONITORING_PROPERTY_KEY_FORMAT, hostIp); .format(MonitoringPropertyGroupService.MONITORING_PROPERTY_KEY_FORMAT, hostIp);
this.properties = monitoringContextDAO.getProperties(instancePropertyGroupName); Properties loaded = monitoringContextDAO.getProperties(instancePropertyGroupName);
if (loaded != null) {
this.properties = loaded;
}
String eaiAgentId = System.getProperty(EAI_AGENTID); String eaiAgentId = System.getProperty(EAI_AGENTID);
if (StringUtils.isBlank(eaiAgentId)) { if (StringUtils.isBlank(eaiAgentId)) {
@@ -1,5 +1,6 @@
package com.eactive.eai.rms.data.entity.onl.inflow; package com.eactive.eai.rms.data.entity.onl.inflow;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page; import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Pageable;
@@ -63,11 +64,19 @@ public class InflowControlLogService
public Iterable<InflowControlLog> findAll(InflowControlHistoryManUISearch uiSearch) { public Iterable<InflowControlLog> findAll(InflowControlHistoryManUISearch uiSearch) {
QInflowControlLog qInflowConfrolLog = QInflowControlLog.inflowControlLog; QInflowControlLog qInflowConfrolLog = QInflowControlLog.inflowControlLog;
String startTime = StringUtils.defaultIfEmpty(uiSearch.getSearchStartTime(), "000000");
String endTime = StringUtils.defaultIfEmpty(uiSearch.getSearchEndTime(), "235959");
BooleanBuilder booleanBuilder = new BooleanBuilder(); BooleanBuilder booleanBuilder = new BooleanBuilder();
booleanBuilder booleanBuilder
.and(qInflowConfrolLog.id.msgdpstyms .and(qInflowConfrolLog.id.msgdpstyms
.between(uiSearch.getSearchStartDate() + "000000000", .between(uiSearch.getSearchStartDate() + startTime + "000",
uiSearch.getSearchEndDate() + "235959999")); uiSearch.getSearchEndDate() + endTime + "999"));
if (!StringUtils.isEmpty(uiSearch.getSearchInstanceName()))
booleanBuilder.and(qInflowConfrolLog.eaisevrinstncname.contains(uiSearch.getSearchInstanceName()));
if (!StringUtils.isEmpty(uiSearch.getSearchApiName()))
booleanBuilder.and(qInflowConfrolLog.eaisvcname.contains(uiSearch.getSearchApiName()));
if (!StringUtils.isEmpty(uiSearch.getSearchAdapterGroupName()))
booleanBuilder.and(qInflowConfrolLog.adptrbzwkgroupname.contains(uiSearch.getSearchAdapterGroupName()));
return super.repository.findAll(booleanBuilder); return super.repository.findAll(booleanBuilder);
} }
} }
@@ -27,6 +27,8 @@ import com.eactive.eai.rms.onl.manage.inflow.history.InflowControlHistoryManUISe
import com.eactive.eai.rms.onl.manage.inflow.inflow.InflowControlManMapper; import com.eactive.eai.rms.onl.manage.inflow.inflow.InflowControlManMapper;
import com.querydsl.core.BooleanBuilder; import com.querydsl.core.BooleanBuilder;
import com.querydsl.core.Tuple; import com.querydsl.core.Tuple;
import com.querydsl.core.types.dsl.BooleanExpression;
import com.querydsl.core.types.dsl.StringPath;
import com.querydsl.jpa.impl.JPAQuery; import com.querydsl.jpa.impl.JPAQuery;
import com.querydsl.jpa.impl.JPAQueryFactory; import com.querydsl.jpa.impl.JPAQueryFactory;
@@ -46,7 +48,12 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
@Autowired @Autowired
InflowControlManMapper mapper; InflowControlManMapper mapper;
public Page<InflowControlServiceDto> findAllForAdapter(Pageable pageable, String searchName) { // 유량제어 미설정(useyn null)은 "사용안함" 검색 시 함께 조회되도록 처리
private static BooleanExpression useYnCondition(StringPath useYnPath, String searchUseYn) {
return "0".equals(searchUseYn) ? useYnPath.eq(searchUseYn).or(useYnPath.isNull()) : useYnPath.eq(searchUseYn);
}
public Page<InflowControlServiceDto> findAllForAdapter(Pageable pageable, String searchName, String searchUseYn) {
JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager); JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager);
QAdapterGroup qAdapterGroup = QAdapterGroup.adapterGroup; QAdapterGroup qAdapterGroup = QAdapterGroup.adapterGroup;
QInflowControl qInflowControl = QInflowControl.inflowControl; QInflowControl qInflowControl = QInflowControl.inflowControl;
@@ -54,6 +61,8 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
BooleanBuilder boolBuilder = new BooleanBuilder(); BooleanBuilder boolBuilder = new BooleanBuilder();
if (!StringUtils.isEmpty(searchName)) if (!StringUtils.isEmpty(searchName))
boolBuilder.and(qAdapterGroup.adptrbzwkgroupname.contains(searchName)); boolBuilder.and(qAdapterGroup.adptrbzwkgroupname.contains(searchName));
if (!StringUtils.isEmpty(searchUseYn))
boolBuilder.and(useYnCondition(qInflowControl.useyn, searchUseYn));
BooleanBuilder adapterWherePredicate = new BooleanBuilder(qAdapterGroup.adptriodstcd BooleanBuilder adapterWherePredicate = new BooleanBuilder(qAdapterGroup.adptriodstcd
.eq("I") .eq("I")
@@ -84,6 +93,10 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
long totalCount = jpaQueryFactory long totalCount = jpaQueryFactory
.select(qAdapterGroup.adptrbzwkgroupname.count()) .select(qAdapterGroup.adptrbzwkgroupname.count())
.from(qAdapterGroup) .from(qAdapterGroup)
.leftJoin(qInflowControl)
.on(qAdapterGroup.adptrbzwkgroupname
.eq(qInflowControl.id.name)
.and(qInflowControl.id.type.eq(ADAPTER_TYPE_INFLOW)))
.where(boolBuilder) .where(boolBuilder)
.fetchOne(); .fetchOne();
@@ -121,17 +134,22 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
return toDto(qAdapterGroup, qInflowControl, tuple); return toDto(qAdapterGroup, qInflowControl, tuple);
} }
public Page<InflowControlServiceDto> findAllForInterface(Pageable pageable, String searchName) { public Page<InflowControlServiceDto> findAllForInterface(Pageable pageable, String searchName, String searchUseYn) {
JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager); JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager);
QInflowControl qInflowControl = QInflowControl.inflowControl; QInflowControl qInflowControl = QInflowControl.inflowControl;
QEAIMessageEntity qEAIMessageEntity = QEAIMessageEntity.eAIMessageEntity; QEAIMessageEntity qEAIMessageEntity = QEAIMessageEntity.eAIMessageEntity;
BooleanBuilder boolBuilder = new BooleanBuilder();
boolBuilder.and(qEAIMessageEntity.eaisvcname.contains(searchName));
if (!StringUtils.isEmpty(searchUseYn))
boolBuilder.and(useYnCondition(qInflowControl.useyn, searchUseYn));
List<Tuple> tupleList = jpaQueryFactory List<Tuple> tupleList = jpaQueryFactory
.select(qInflowControl, qEAIMessageEntity.eaisvcname, qEAIMessageEntity.eaisvcdesc) .select(qInflowControl, qEAIMessageEntity.eaisvcname, qEAIMessageEntity.eaisvcdesc)
.from(qEAIMessageEntity) .from(qEAIMessageEntity)
.leftJoin(qInflowControl) .leftJoin(qInflowControl)
.on(qInflowControl.id.type.eq(INTERFACE_TYPE_INFLOW).and(qInflowControl.id.name.eq(qEAIMessageEntity.eaisvcname))) .on(qInflowControl.id.type.eq(INTERFACE_TYPE_INFLOW).and(qInflowControl.id.name.eq(qEAIMessageEntity.eaisvcname)))
.where(qEAIMessageEntity.eaisvcname.contains(searchName)) .where(boolBuilder)
.orderBy(qEAIMessageEntity.eaisvcname.asc()) .orderBy(qEAIMessageEntity.eaisvcname.asc())
.offset(pageable.getOffset()) .offset(pageable.getOffset())
.limit(pageable.getPageSize()) .limit(pageable.getPageSize())
@@ -145,7 +163,9 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
long totalCount = jpaQueryFactory long totalCount = jpaQueryFactory
.select(qEAIMessageEntity.eaisvcname.count()) .select(qEAIMessageEntity.eaisvcname.count())
.from(qEAIMessageEntity) .from(qEAIMessageEntity)
.where(qEAIMessageEntity.eaisvcname.contains(searchName)) .leftJoin(qInflowControl)
.on(qInflowControl.id.type.eq(INTERFACE_TYPE_INFLOW).and(qInflowControl.id.name.eq(qEAIMessageEntity.eaisvcname)))
.where(boolBuilder)
.fetchOne(); .fetchOne();
return new PageImpl<>(dtoList, pageable, totalCount); return new PageImpl<>(dtoList, pageable, totalCount);
} }
@@ -199,19 +219,24 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
return toDto(qClientEntity, qInflowControl, tuple); return toDto(qClientEntity, qInflowControl, tuple);
} }
public Page<InflowControlServiceDto> findAllForClient(Pageable pageable, String searchName) { public Page<InflowControlServiceDto> findAllForClient(Pageable pageable, String searchName, String searchUseYn) {
JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager); JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager);
QInflowControl qInflowControl = QInflowControl.inflowControl; QInflowControl qInflowControl = QInflowControl.inflowControl;
QClientEntity qClientEntity = QClientEntity.clientEntity; QClientEntity qClientEntity = QClientEntity.clientEntity;
BooleanBuilder boolBuilder = new BooleanBuilder();
boolBuilder.and(qClientEntity.clientname.contains(searchName));
if (!StringUtils.isEmpty(searchUseYn))
boolBuilder.and(useYnCondition(qInflowControl.useyn, searchUseYn));
List<Tuple> tupleList = jpaQueryFactory List<Tuple> tupleList = jpaQueryFactory
.select(qInflowControl, qClientEntity.clientid, qClientEntity.clientname) .select(qInflowControl, qClientEntity.clientid, qClientEntity.clientname)
.from(qClientEntity) .from(qClientEntity)
.leftJoin(qInflowControl) .leftJoin(qInflowControl)
.on(qInflowControl.id.type.eq(CLIENT_TYPE_INFLOW) .on(qInflowControl.id.type.eq(CLIENT_TYPE_INFLOW)
.and(qInflowControl.id.name.eq(qClientEntity.clientid))) .and(qInflowControl.id.name.eq(qClientEntity.clientid)))
.where(qClientEntity.clientname.contains(searchName)) .where(boolBuilder)
.orderBy(qClientEntity.clientname.asc()) .orderBy(qClientEntity.clientname.asc())
.offset(pageable.getOffset()) .offset(pageable.getOffset())
.limit(pageable.getPageSize()) .limit(pageable.getPageSize())
@@ -225,7 +250,10 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
long totalCount = jpaQueryFactory long totalCount = jpaQueryFactory
.select(qClientEntity.clientname.count()) .select(qClientEntity.clientname.count())
.from(qClientEntity) .from(qClientEntity)
.where(qClientEntity.clientname.contains(searchName)) .leftJoin(qInflowControl)
.on(qInflowControl.id.type.eq(CLIENT_TYPE_INFLOW)
.and(qInflowControl.id.name.eq(qClientEntity.clientid)))
.where(boolBuilder)
.fetchOne(); .fetchOne();
return new PageImpl<>(dtoList, pageable, totalCount); return new PageImpl<>(dtoList, pageable, totalCount);
} }
@@ -266,12 +294,21 @@ public class InflowControlService extends AbstractDataService<InflowControl, Inf
QInflowControlLog qInflowConfrolLog = QInflowControlLog.inflowControlLog; QInflowControlLog qInflowConfrolLog = QInflowControlLog.inflowControlLog;
QInflowControlGroup qinflowControlGroup = QInflowControlGroup.inflowControlGroup; QInflowControlGroup qinflowControlGroup = QInflowControlGroup.inflowControlGroup;
String startTime = StringUtils.defaultIfEmpty(uiSearch.getSearchStartTime(), "000000");
String endTime = StringUtils.defaultIfEmpty(uiSearch.getSearchEndTime(), "235959");
BooleanBuilder predicate = new BooleanBuilder(); BooleanBuilder predicate = new BooleanBuilder();
predicate predicate
.and(qInflowConfrolLog.id.msgdpstyms .and(qInflowConfrolLog.id.msgdpstyms
.between(uiSearch.getSearchStartDate() + "000000000", .between(uiSearch.getSearchStartDate() + startTime + "000",
uiSearch.getSearchEndDate() + "235959999")); uiSearch.getSearchEndDate() + endTime + "999"));
if (!StringUtils.isEmpty(uiSearch.getSearchInstanceName()))
predicate.and(qInflowConfrolLog.eaisevrinstncname.contains(uiSearch.getSearchInstanceName()));
if (!StringUtils.isEmpty(uiSearch.getSearchApiName()))
predicate.and(qInflowConfrolLog.eaisvcname.contains(uiSearch.getSearchApiName()));
if (!StringUtils.isEmpty(uiSearch.getSearchAdapterGroupName()))
predicate.and(qInflowConfrolLog.adptrbzwkgroupname.contains(uiSearch.getSearchAdapterGroupName()));
return getJPAQueryFactory() return getJPAQueryFactory()
.select( .select(
qInflowConfrolLog, qInflowConfrolLog,
@@ -43,12 +43,6 @@ public class DjbProperty {
) )
private String apiAllowIpList = "10.15.106.*, 10.14.8.*, 10.15.8.*, 192.168.240.*, 127.0.0.1, 192.168.132.*, 192.168.131.*"; private String apiAllowIpList = "10.15.106.*, 10.14.8.*, 10.15.8.*, 192.168.240.*, 127.0.0.1, 192.168.132.*, 192.168.131.*";
@DjbPropertyValue(
key = "djb.api_gw_metric.page_size",
description = "API GW Metric 조회시 페이지 크기 설정 (Integer, 0 = 무한, 기본값 10000)",
defaultValue = "10000"
)
private Integer apiGwMetricPageSize = 10000;
@@ -219,7 +219,12 @@ public class UmsService {
} else if ("KAKAO".equals(messageRequest.getMessageType())) { } else if ("KAKAO".equals(messageRequest.getMessageType())) {
dataVO.setLtrs_snd_tycd("2"); // 1:SMS 2:LMS/MMS dataVO.setLtrs_snd_tycd("2"); // 1:SMS 2:LMS/MMS
dataVO.setMsg_snd_tycd("1008"); // 알림톡 메세지 종류 0000:SMS, 1000:LMS, 1008:알림톡, .... dataVO.setMsg_snd_tycd("1008"); // 알림톡 메세지 종류 0000:SMS, 1000:LMS, 1008:알림톡, ....
dataVO.setAlmtk_snd_prfl_key(propertyService.getPropertyValue("Monitoring", "djb.ums.sms.almtk_snd_prtl_key", "")); // 플러스친구아이디 //ADMIN으로 시작하면 제주은행 임직원, 나머지는 제주은행 고객용
if (messageRequest.getMessageCode().name().startsWith("ADMIN")) {
dataVO.setAlmtk_snd_prfl_key(propertyService.getPropertyValue("Monitoring", "djb.ums.sms.almtk_snd_prtl_key.intra", "")); // 제주은행 임직원 플러스친구아이디
} else {
dataVO.setAlmtk_snd_prfl_key(propertyService.getPropertyValue("Monitoring", "djb.ums.sms.almtk_snd_prtl_key.public", "")); // 제주은행 플러스친구아이디
}
dataVO.setAlmtk_tmplt_cd(BZWK_DVCD + TEAM_DVCD + SUB_BZWK_CD + "001"); // 템플릿코드 dataVO.setAlmtk_tmplt_cd(BZWK_DVCD + TEAM_DVCD + SUB_BZWK_CD + "001"); // 템플릿코드
dataVO.setAlmtk_err_ltrs_snd_yn("Y"); // 오류자문자발송여부 dataVO.setAlmtk_err_ltrs_snd_yn("Y"); // 오류자문자발송여부
dataVO.setAlmtk_btn_trnm_tycd("2"); // 카카오버튼전송방식 1-format string 2-JSON 3-XML dataVO.setAlmtk_btn_trnm_tycd("2"); // 카카오버튼전송방식 1-format string 2-JSON 3-XML
@@ -1,23 +1,5 @@
package com.eactive.eai.rms.onl.apim.obp; package com.eactive.eai.rms.onl.apim.obp;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.time.temporal.ChronoUnit;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import java.util.Set;
import java.util.stream.Collectors;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.dao.DataIntegrityViolationException;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.eactive.apim.portal.apprequest.entity.AppRequest; import com.eactive.apim.portal.apprequest.entity.AppRequest;
import com.eactive.apim.portal.apprequest.repository.AppRequestRepository; import com.eactive.apim.portal.apprequest.repository.AppRequestRepository;
import com.eactive.apim.portal.obp.entity.ObpGwMetric; import com.eactive.apim.portal.obp.entity.ObpGwMetric;
@@ -28,7 +10,18 @@ import com.eactive.eai.rms.common.util.CommonUtil;
import com.eactive.eai.rms.data.entity.onl.apim.obp.ObpGwMetricJpaDAO; import com.eactive.eai.rms.data.entity.onl.apim.obp.ObpGwMetricJpaDAO;
import com.eactive.eai.rms.data.entity.onl.apim.obp.ObpGwMetricService; import com.eactive.eai.rms.data.entity.onl.apim.obp.ObpGwMetricService;
import com.eactive.eai.rms.data.entity.onl.apim.obp.ObpGwMetricVO; import com.eactive.eai.rms.data.entity.onl.apim.obp.ObpGwMetricVO;
import com.eactive.eai.rms.ext.djb.common.DjbPropertyHolder; //import com.eactive.ext.kjb.common.KjbPropertyHolder;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.dao.DataIntegrityViolationException;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.time.temporal.ChronoUnit;
import java.util.*;
import java.util.stream.Collectors;
/** /**
* ObpGwMetric Man Service - 비즈니스 로직 * ObpGwMetric Man Service - 비즈니스 로직
@@ -335,7 +328,7 @@ public class ObpGwMetricManService extends BaseService {
DataSourceTypeManager.getDataSourceType(DataSourceTypeManager.MONITORING)); DataSourceTypeManager.getDataSourceType(DataSourceTypeManager.MONITORING));
// KjbProperty에서 pageSize 읽기 // KjbProperty에서 pageSize 읽기
Integer pageSize = DjbPropertyHolder.get().getApiGwMetricPageSize(); Integer pageSize = null; //KjbPropertyHolder.get().getApiGwMetricPageSize();
if (pageSize == null) { if (pageSize == null) {
pageSize = 10000; // 기본값 (null 안전 처리) pageSize = 10000; // 기본값 (null 안전 처리)
} }
@@ -17,6 +17,7 @@ import com.eactive.eai.data.entity.onl.server.EAIServer;
import com.eactive.eai.rms.common.base.OnlBaseService; import com.eactive.eai.rms.common.base.OnlBaseService;
import com.eactive.eai.rms.data.entity.onl.adapter.AdapterGroupService; import com.eactive.eai.rms.data.entity.onl.adapter.AdapterGroupService;
import com.eactive.eai.rms.data.entity.onl.server.EAIServerService; import com.eactive.eai.rms.data.entity.onl.server.EAIServerService;
import com.eactive.eai.rms.onl.common.exception.BizException;
@Service @Service
@Transactional @Transactional
@@ -78,6 +79,11 @@ public class ServerManService extends OnlBaseService {
} }
public void insert(EAIServerUI eaiServerUI) { public void insert(EAIServerUI eaiServerUI) {
String eaiSevrInstncName = eaiServerUI.getEaiSevrInstncName();
if (eaiServerService.existsById(eaiSevrInstncName)) {
throw new BizException("서버 인스턴스명[" + eaiSevrInstncName + "]은 이미 등록되어 있습니다.");
}
EAIServer eaiServer = eaiServerUIMapper.toEntity(eaiServerUI); EAIServer eaiServer = eaiServerUIMapper.toEntity(eaiServerUI);
eaiServerService.save(eaiServer); eaiServerService.save(eaiServer);
} }
@@ -59,8 +59,8 @@ public class InflowGroupControlManController extends OnlBaseAnnotationController
*/ */
@RequestMapping(value = "/onl/admin/inflow/inflowGroupControlMan.json", params = "cmd=LIST") @RequestMapping(value = "/onl/admin/inflow/inflowGroupControlMan.json", params = "cmd=LIST")
public ResponseEntity<GridResponse<InflowGroupControlManUI>> selectList(HttpServletRequest request, public ResponseEntity<GridResponse<InflowGroupControlManUI>> selectList(HttpServletRequest request,
Pageable pageVo, String searchGroupName) { Pageable pageVo, String searchGroupName, String searchUseYn) {
Page<InflowGroupControlManUI> uiPage = service.selectGroupList(pageVo, searchGroupName); Page<InflowGroupControlManUI> uiPage = service.selectGroupList(pageVo, searchGroupName, searchUseYn);
return ResponseEntity.ok(new GridResponse<>(uiPage)); return ResponseEntity.ok(new GridResponse<>(uiPage));
} }
@@ -61,7 +61,7 @@ public class InflowGroupControlManService extends BaseService {
/** /**
* 그룹 목록 조회 * 그룹 목록 조회
*/ */
public Page<InflowGroupControlManUI> selectGroupList(Pageable pageable, String searchGroupName) { public Page<InflowGroupControlManUI> selectGroupList(Pageable pageable, String searchGroupName, String searchUseYn) {
JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager); JPAQueryFactory jpaQueryFactory = new JPAQueryFactory(entityManager);
QInflowControlGroup qGroup = QInflowControlGroup.inflowControlGroup; QInflowControlGroup qGroup = QInflowControlGroup.inflowControlGroup;
@@ -69,6 +69,10 @@ public class InflowGroupControlManService extends BaseService {
if (!StringUtils.isEmpty(searchGroupName)) { if (!StringUtils.isEmpty(searchGroupName)) {
boolBuilder.and(qGroup.groupName.contains(searchGroupName)); boolBuilder.and(qGroup.groupName.contains(searchGroupName));
} }
if (!StringUtils.isEmpty(searchUseYn)) {
// 유량제어 미설정(useYn null)은 "사용안함" 검색 시 함께 조회되도록 처리
boolBuilder.and("0".equals(searchUseYn) ? qGroup.useYn.eq(searchUseYn).or(qGroup.useYn.isNull()) : qGroup.useYn.eq(searchUseYn));
}
List<InflowControlGroup> groupList = jpaQueryFactory List<InflowControlGroup> groupList = jpaQueryFactory
.selectFrom(qGroup) .selectFrom(qGroup)
@@ -24,4 +24,29 @@ public class InflowControlHistoryManUISearch {
* 유량제어일 끝(20231221) * 유량제어일 끝(20231221)
*/ */
private String searchEndDate; private String searchEndDate;
/**
* 유량제어일 시작 시간(000000)
*/
private String searchStartTime;
/**
* 유량제어일 끝 시간(235959)
*/
private String searchEndTime;
/**
* 인스턴스명
*/
private String searchInstanceName;
/**
* API 명
*/
private String searchApiName;
/**
* 어댑터그룹명
*/
private String searchAdapterGroupName;
} }
@@ -42,8 +42,8 @@ public class InflowAdapterControlManController extends OnlBaseAnnotationControll
@RequestMapping(value = "/onl/admin/inflow/inflowAdapterControlMan.json", params = "cmd=LIST") @RequestMapping(value = "/onl/admin/inflow/inflowAdapterControlMan.json", params = "cmd=LIST")
public ResponseEntity<GridResponse<InflowControlManUI>> selectList(HttpServletRequest request, Pageable pageVo, public ResponseEntity<GridResponse<InflowControlManUI>> selectList(HttpServletRequest request, Pageable pageVo,
String searchName) { String searchName, String searchUseYn) {
Page<InflowControlManUI> uiPage = service.selectAdapterList(pageVo, searchName); Page<InflowControlManUI> uiPage = service.selectAdapterList(pageVo, searchName, searchUseYn);
return ResponseEntity.ok(new GridResponse<>(uiPage)); return ResponseEntity.ok(new GridResponse<>(uiPage));
} }
@@ -19,7 +19,9 @@ import com.eactive.eai.agent.command.CommonCommand;
import com.eactive.eai.rms.common.base.OnlBaseAnnotationController; import com.eactive.eai.rms.common.base.OnlBaseAnnotationController;
import com.eactive.eai.rms.common.combo.ComboService; import com.eactive.eai.rms.common.combo.ComboService;
import com.eactive.eai.rms.common.combo.ComboVo; import com.eactive.eai.rms.common.combo.ComboVo;
import com.eactive.eai.rms.common.util.CommonUtil;
import com.eactive.eai.rms.common.vo.GridResponse; import com.eactive.eai.rms.common.vo.GridResponse;
import com.eactive.eai.rms.common.vo.SimpleResponse;
@Controller @Controller
public class InflowClientControlManController extends OnlBaseAnnotationController { public class InflowClientControlManController extends OnlBaseAnnotationController {
@@ -42,8 +44,8 @@ public class InflowClientControlManController extends OnlBaseAnnotationControlle
@RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=LIST") @RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=LIST")
public ResponseEntity<GridResponse<InflowControlManUI>> selectList(HttpServletRequest request, Pageable pageVo, public ResponseEntity<GridResponse<InflowControlManUI>> selectList(HttpServletRequest request, Pageable pageVo,
String searchName) { String searchName, String searchUseYn) {
Page<InflowControlManUI> uiPage = service.selectClientList(pageVo, searchName); Page<InflowControlManUI> uiPage = service.selectClientList(pageVo, searchName, searchUseYn);
return ResponseEntity.ok(new GridResponse<>(uiPage)); return ResponseEntity.ok(new GridResponse<>(uiPage));
} }
@@ -55,22 +57,22 @@ public class InflowClientControlManController extends OnlBaseAnnotationControlle
} }
@RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=UPDATE") @RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=UPDATE")
public String save(HttpServletRequest request, HttpServletResponse response, InflowControlManUI ui) public ResponseEntity<SimpleResponse> save(HttpServletRequest request, HttpServletResponse response, InflowControlManUI ui)
throws Exception { throws Exception {
service.mergeClient(ui); service.mergeClient(ui);
CommonCommand command = new CommonCommand("com.eactive.eai.agent.inflow.ReloadInflowClientControlCommand", CommonCommand command = new CommonCommand("com.eactive.eai.agent.inflow.ReloadInflowClientControlCommand", ui.getName());
ui.getName()); HashMap<String, Object> returnMap = agentUtilService.broadcast(command);
agentUtilService.broadcast(command); SimpleResponse simpleResponse = SimpleResponse.of(CommonUtil.getMapString(returnMap, true));
return null; return ResponseEntity.ok(simpleResponse);
} }
@RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=DELETE") @RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=DELETE")
public String delete(HttpServletRequest request, HttpServletResponse response, String name) throws Exception { public ResponseEntity<SimpleResponse> delete(HttpServletRequest request, HttpServletResponse response, String name) throws Exception {
service.deleteClient(name); service.deleteClient(name);
CommonCommand command = new CommonCommand("com.eactive.eai.agent.inflow.RemoveInflowClientControlCommand", CommonCommand command = new CommonCommand("com.eactive.eai.agent.inflow.RemoveInflowClientControlCommand", name);
name); HashMap<String, Object> returnMap = agentUtilService.broadcast(command);
agentUtilService.broadcast(command); SimpleResponse simpleResponse = SimpleResponse.of(CommonUtil.getMapString(returnMap, true));
return null; return ResponseEntity.ok(simpleResponse);
} }
@RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=LIST_INIT_COMBO") @RequestMapping(value = "/onl/admin/inflow/inflowClientControlMan.json", params = "cmd=LIST_INIT_COMBO")
@@ -1,5 +1,6 @@
package com.eactive.eai.rms.onl.manage.inflow.inflow; package com.eactive.eai.rms.onl.manage.inflow.inflow;
import java.net.URI;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
@@ -16,6 +17,7 @@ import org.springframework.data.domain.Pageable;
import org.springframework.http.ResponseEntity; import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.web.client.RestTemplate; import org.springframework.web.client.RestTemplate;
import org.springframework.web.util.UriComponentsBuilder;
import com.eactive.eai.data.entity.onl.inflow.InflowControl; import com.eactive.eai.data.entity.onl.inflow.InflowControl;
import com.eactive.eai.data.entity.onl.inflow.InflowControlId; import com.eactive.eai.data.entity.onl.inflow.InflowControlId;
@@ -50,8 +52,8 @@ public class InflowControlManService extends BaseService {
private RestTemplate restTemplate = new RestTemplate(); private RestTemplate restTemplate = new RestTemplate();
// 어댑터 유량제어 // 어댑터 유량제어
public Page<InflowControlManUI> selectAdapterList(Pageable pageable, String searchName) { public Page<InflowControlManUI> selectAdapterList(Pageable pageable, String searchName, String searchUseYn) {
Page<InflowControlServiceDto> dtoList = service.findAllForAdapter(pageable, searchName); Page<InflowControlServiceDto> dtoList = service.findAllForAdapter(pageable, searchName, searchUseYn);
return dtoList.map(mapper::toVo); return dtoList.map(mapper::toVo);
} }
@@ -72,6 +74,9 @@ public class InflowControlManService extends BaseService {
} else { } else {
entity = mapper.toEntity(ui); entity = mapper.toEntity(ui);
} }
if (entity.getThreshold() == null || StringUtils.isEmpty(entity.getThresholdtimeunit())) {
entity.setThreshold(0);
}
service.save(entity); service.save(entity);
} }
@@ -81,8 +86,8 @@ public class InflowControlManService extends BaseService {
} }
// 인터페이스 유량제어 // 인터페이스 유량제어
public Page<InflowControlManUI> selectInterfaceList(Pageable pageable, String searchName) { public Page<InflowControlManUI> selectInterfaceList(Pageable pageable, String searchName, String searchUseYn) {
Page<InflowControlServiceDto> dtoList = service.findAllForInterface(pageable, searchName); Page<InflowControlServiceDto> dtoList = service.findAllForInterface(pageable, searchName, searchUseYn);
return dtoList.map(mapper::toVo); return dtoList.map(mapper::toVo);
} }
@@ -102,6 +107,9 @@ public class InflowControlManService extends BaseService {
} else { } else {
entity = mapper.toEntity(ui); entity = mapper.toEntity(ui);
} }
if (entity.getThreshold() == null || StringUtils.isEmpty(entity.getThresholdtimeunit())) {
entity.setThreshold(0);
}
service.save(entity); service.save(entity);
} }
@@ -112,8 +120,8 @@ public class InflowControlManService extends BaseService {
// 클라이언트 유량제어 // 클라이언트 유량제어
public Page<InflowControlManUI> selectClientList(Pageable pageable, String searchName) { public Page<InflowControlManUI> selectClientList(Pageable pageable, String searchName, String searchUseYn) {
Page<InflowControlServiceDto> dtoList = service.findAllForClient(pageable, searchName); Page<InflowControlServiceDto> dtoList = service.findAllForClient(pageable, searchName, searchUseYn);
return dtoList.map(mapper::toVo); return dtoList.map(mapper::toVo);
} }
@@ -133,6 +141,9 @@ public class InflowControlManService extends BaseService {
} else { } else {
entity = mapper.toEntity(ui); entity = mapper.toEntity(ui);
} }
if (entity.getThreshold() == null || StringUtils.isEmpty(entity.getThresholdtimeunit())) {
entity.setThreshold(0);
}
service.save(entity); service.save(entity);
} }
@@ -172,9 +183,12 @@ public class InflowControlManService extends BaseService {
serverStatus.put("serverPort", serverPort); serverStatus.put("serverPort", serverPort);
try { try {
String url = String.format("http://%s:%s/manage/inflow/%s/%s/bucket-status", URI uri = UriComponentsBuilder.fromHttpUrl(String.format("http://%s:%s/manage/inflow", serverIp, serverPort))
serverIp, serverPort, target, targetId); .pathSegment(target, targetId, "bucket-status")
ResponseEntity<Map> response = restTemplate.getForEntity(url, Map.class); .build()
.encode()
.toUri();
ResponseEntity<Map> response = restTemplate.getForEntity(uri, Map.class);
if (response.getBody() != null && Boolean.TRUE.equals(response.getBody().get("success"))) { if (response.getBody() != null && Boolean.TRUE.equals(response.getBody().get("success"))) {
serverStatus.put("status", "online"); serverStatus.put("status", "online");
@@ -42,8 +42,8 @@ public class InflowInterfaceControlManController extends OnlBaseAnnotationContro
@RequestMapping(value = "/onl/admin/inflow/inflowInterfaceControlMan.json", params = "cmd=LIST") @RequestMapping(value = "/onl/admin/inflow/inflowInterfaceControlMan.json", params = "cmd=LIST")
public ResponseEntity<GridResponse<InflowControlManUI>> selectList(HttpServletRequest request, Pageable pageVo, public ResponseEntity<GridResponse<InflowControlManUI>> selectList(HttpServletRequest request, Pageable pageVo,
String searchName) { String searchName, String searchUseYn) {
Page<InflowControlManUI> uiPage = service.selectInterfaceList(pageVo, searchName); Page<InflowControlManUI> uiPage = service.selectInterfaceList(pageVo, searchName, searchUseYn);
return ResponseEntity.ok(new GridResponse<>(uiPage)); return ResponseEntity.ok(new GridResponse<>(uiPage));
} }
@@ -101,6 +101,11 @@ public class Transform2Controller extends BaseController {
public String popupCalendarView() { public String popupCalendarView() {
return "/onl/admin/rule/transform2/transform2ManPopupCalendar"; return "/onl/admin/rule/transform2/transform2ManPopupCalendar";
} }
@GetMapping(value = "/onl/admin/rule/transform2/transform2Man.view", params = "cmd=API_POPUP")
public String apiPopupView() {
return "/onl/admin/rule/transform2/transform2ManApiPopup";
}
@PostMapping(value = "/onl/admin/rule/transform2/transform2Man.json", params = "cmd=LIST_INIT_COMBO") @PostMapping(value = "/onl/admin/rule/transform2/transform2Man.json", params = "cmd=LIST_INIT_COMBO")
public ResponseEntity<Map<String, Object>> initCombo(HttpServletRequest request, String eaiSvcName, String cnvsnName) { public ResponseEntity<Map<String, Object>> initCombo(HttpServletRequest request, String eaiSvcName, String cnvsnName) {
@@ -448,14 +448,24 @@ public class ApiSpecManService {
// 헤더/바디 분리 // 헤더/바디 분리
RequestComponents components = separateHeaderAndBody(requestLayout.getLayoutItems()); RequestComponents components = separateHeaderAndBody(requestLayout.getLayoutItems());
// 헤더 파라미터 처리 boolean bodyRequired = isRequestBodyRequired(httpMethod);
if (!components.headerItems.isEmpty()) {
// 헤더 파라미터 + (POST/PUT 이 아니면) 요청 바디 항목을 쿼리스트링 파라미터로 함께 담는다.
boolean hasHeader = !components.headerItems.isEmpty();
boolean queryFromBody = !bodyRequired && !components.bodyItems.isEmpty();
if (hasHeader || queryFromBody) {
ArrayNode parameters = operation.putArray("parameters"); ArrayNode parameters = operation.putArray("parameters");
generateHeaderParameters(parameters, components.headerItems); if (hasHeader) {
generateHeaderParameters(parameters, components.headerItems);
}
// GET/DELETE 등 바디 미사용 메소드: 요청 레이아웃 바디 항목 → 쿼리 파라미터(in=query)
if (queryFromBody) {
generateQueryParameters(parameters, components.bodyItems);
}
} }
// Body 처리 (POST, PUT 메소드인 경우) // Body 처리 (POST, PUT 메소드인 경우)
if (isRequestBodyRequired(httpMethod)) { if (bodyRequired) {
ObjectNode requestBody = operation.putObject("requestBody"); ObjectNode requestBody = operation.putObject("requestBody");
requestBody.put("required", true); requestBody.put("required", true);
ObjectNode content = requestBody.putObject("content"); ObjectNode content = requestBody.putObject("content");
@@ -561,6 +571,35 @@ public class ApiSpecManService {
} }
} }
/**
* GET/DELETE 등 바디 미사용 메소드: 요청 레이아웃 바디 항목을 쿼리스트링 파라미터(in=query)로 매핑.
* 스칼라 FIELD 만 대상(GROUP/GRID 중첩 객체·배열은 쿼리스트링에 부적합하여 제외), root(serno 0)는 스킵.
*/
private void generateQueryParameters(ArrayNode parameters, List<LayoutItemUI> bodyItems) {
for (LayoutItemUI item : bodyItems) {
if (item.getLoutItemSerno() != null && item.getLoutItemSerno() == 0) {
continue;
}
if (!"FIELD".equalsIgnoreCase(item.getLoutItemType())) {
continue;
}
ObjectNode parameter = parameters.addObject();
parameter.put("name", item.getLoutItemName());
parameter.put("in", "query");
if (StringUtils.isNotEmpty(item.getLoutItemDesc())) {
parameter.put("description", item.getLoutItemDesc());
}
parameter.put("required", false); // 기본값 false, 필요시 사용자가 변경
ObjectNode schema = parameter.putObject("schema");
schema.put("type", mapSwaggerType(item.getLoutItemDataType()));
int length = item.getLoutItemLength();
if (length > 0) {
schema.put("maxLength", length);
}
}
}
private void generateResponseHeaders(ObjectNode headers, List<LayoutItemUI> headerItems) { private void generateResponseHeaders(ObjectNode headers, List<LayoutItemUI> headerItems) {
for (LayoutItemUI item : headerItems) { for (LayoutItemUI item : headerItems) {
if ("FIELD".equalsIgnoreCase(item.getLoutItemType())) { if ("FIELD".equalsIgnoreCase(item.getLoutItemType())) {
@@ -637,6 +676,7 @@ public class ApiSpecManService {
return "integer"; return "integer";
case "DECIMAL": case "DECIMAL":
case "DOUBLE": case "DOUBLE":
case "BIGDECIMAL":
return "number"; return "number";
case "BOOLEAN": case "BOOLEAN":
return "boolean"; return "boolean";