DataApi 개선 및 테스트 서버와의 테스트 수행
This commit is contained in:
parent
3358abbc5f
commit
61fee5e9dd
9
data/dataxml/uac.service.nlib.col.getItemInfo_GET.xml
Normal file
9
data/dataxml/uac.service.nlib.col.getItemInfo_GET.xml
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||||
|
<results>
|
||||||
|
<!-- 상세내용 -->
|
||||||
|
<resultCode>S001</resultCode>
|
||||||
|
<resultMessage>정상적으로 조회되었습니다.</resultMessage>
|
||||||
|
<masterId>1111111</masterId>
|
||||||
|
<title>제목입니다.</title>
|
||||||
|
<typeCodeNm>도서간행물</typeCodeNm>
|
||||||
|
</results>
|
||||||
@ -1,47 +0,0 @@
|
|||||||
package nlib.sample.service.impl;
|
|
||||||
|
|
||||||
import org.springframework.stereotype.Repository;
|
|
||||||
|
|
||||||
import nlib.restful.DataApi;
|
|
||||||
import nlib.restful.service.DataApiReqVO;
|
|
||||||
import nlib.restful.service.DataApiResVO;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* @Class Name : SampleDataApiDAO.java
|
|
||||||
*
|
|
||||||
* @Description : RESTful API 호출 샘플
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* @프로젝트명: 지방문화원 통합자료관리시스템 구축사업 (2021)
|
|
||||||
*
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* @ ------------ -------- ---------------------------
|
|
||||||
* @ 수정일 수정자 수정내용
|
|
||||||
* @ ------------ -------- ---------------------------
|
|
||||||
* @ 2021. 6. 22. KNKIM 최초 생성
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* @author 이씨플라자 * DIGITALSHIP KNKIM
|
|
||||||
* @since 2021. 6. 22.
|
|
||||||
* @version 1.0
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Repository("sampleDataApiDAO")
|
|
||||||
public class SampleDataApiDAO extends DataApi {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 주 자원의 URI
|
|
||||||
*/
|
|
||||||
public static final String RESOURCE_URI = "/uac/service/exports";
|
|
||||||
|
|
||||||
public DataApiResVO getSampleInfo(DataApiReqVO reqVO) throws Exception {
|
|
||||||
|
|
||||||
// URI가 다른 경우, 해당 URI 설정
|
|
||||||
reqVO.setReqUrl(RESOURCE_URI);
|
|
||||||
|
|
||||||
return get(reqVO);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
86
src/main/webapp/WEB-INF/jsp/nlib/sample/getItemInfo.jsp
Normal file
86
src/main/webapp/WEB-INF/jsp/nlib/sample/getItemInfo.jsp
Normal file
@ -0,0 +1,86 @@
|
|||||||
|
<%
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* @Class Name : getSampleInfo.jsp
|
||||||
|
*
|
||||||
|
* @Description : RESTful API 호출 샘플
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @프로젝트명: 지방문화원 통합자료관리시스템 구축사업 (2021)
|
||||||
|
*
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* @ ------------ -------- ---------------------------
|
||||||
|
* @ 수정일 수정자 수정내용
|
||||||
|
* @ ------------ -------- ---------------------------
|
||||||
|
* @ 2021. 6. 15. KNKIM 최초 생성
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @author 이씨플라자 * DIGITALSHIP KNKIM
|
||||||
|
* @since 2021. 6. 15.
|
||||||
|
* @version 1.0
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
%>
|
||||||
|
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
|
||||||
|
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||||
|
<%@ taglib prefix="ui" uri="http://egovframework.gov/ctl/ui" %>
|
||||||
|
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
|
||||||
|
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
|
||||||
|
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
|
||||||
|
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
|
||||||
|
<%@ taglib prefix="validator" uri="http://www.springmodules.org/tags/commons-validator" %>
|
||||||
|
<c:set var="pageTitle"><spring:message code="nlib.title"/> - 결과</c:set>
|
||||||
|
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>${pageTitle}</title>
|
||||||
|
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||||
|
|
||||||
|
<script type="text/javaScript" language="javascript">
|
||||||
|
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<!-- javascript warning tag -->
|
||||||
|
<noscript class="noScriptTitle"><spring:message code="common.noScriptTitle.msg" /></noscript>
|
||||||
|
<form
|
||||||
|
action="${pageContext.request.contextPath}/sample/getItemInfo.do"
|
||||||
|
method="post">
|
||||||
|
|
||||||
|
<div class="wTableFrm">
|
||||||
|
<!-- 타이틀 -->
|
||||||
|
<h2>${pageTitle}</h2>
|
||||||
|
|
||||||
|
<div style="clear:both;">Server Protocol : ${serverProtocol}</div>
|
||||||
|
<div style="clear:both;">Server IP : ${serverIp}</div>
|
||||||
|
<div style="clear:both;">Server PORT : ${serverPort}</div>
|
||||||
|
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
|
||||||
|
mngOrgCd : <input name="mngOrgCd" id="mngOrgCd" value="SU01" /> <br />
|
||||||
|
masterId : <input name="masterId" id="masterId" value="UR-408A9832D25C42289D9B1FC81FDA8360" /> <br />
|
||||||
|
typeDivCd : <input name="typeDivCd" id="typeDivCd" value="IT_MUSE" /> <br />
|
||||||
|
|
||||||
|
<br />
|
||||||
|
resultCode : <input name="resultCode" id="resultCode" value="${resultCode}" /> <br />
|
||||||
|
resultMessage : <input name="resultCode" id="resultCode" value="${resultMessage}" /> <br />
|
||||||
|
info.title : <input name="info.name" id="info.name" value="${info.title}" /> <br />
|
||||||
|
info.typeCodeNm : <input name="info.name" id="info.name" value="${info.typeCodeNm}" /> <br />
|
||||||
|
info.masterId : <input name="info.name" id="info.name" value="${info.masterId}" /> <br />
|
||||||
|
<br />
|
||||||
|
|
||||||
|
<div style="clear:both;"></div>
|
||||||
|
|
||||||
|
<input type="submit" id="btnSubmit" name="btnSubmit" value="전송" />
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
98
src/main/webapp/WEB-INF/jsp/nlib/sample/listRentItem.jsp
Normal file
98
src/main/webapp/WEB-INF/jsp/nlib/sample/listRentItem.jsp
Normal file
@ -0,0 +1,98 @@
|
|||||||
|
<%
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* @Class Name : getSampleInfo.jsp
|
||||||
|
*
|
||||||
|
* @Description : RESTful API 호출 샘플
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @프로젝트명: 지방문화원 통합자료관리시스템 구축사업 (2021)
|
||||||
|
*
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* @ ------------ -------- ---------------------------
|
||||||
|
* @ 수정일 수정자 수정내용
|
||||||
|
* @ ------------ -------- ---------------------------
|
||||||
|
* @ 2021. 6. 15. KNKIM 최초 생성
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @author 이씨플라자 * DIGITALSHIP KNKIM
|
||||||
|
* @since 2021. 6. 15.
|
||||||
|
* @version 1.0
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
%>
|
||||||
|
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
|
||||||
|
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||||
|
<%@ taglib prefix="ui" uri="http://egovframework.gov/ctl/ui" %>
|
||||||
|
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
|
||||||
|
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
|
||||||
|
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
|
||||||
|
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
|
||||||
|
<%@ taglib prefix="validator" uri="http://www.springmodules.org/tags/commons-validator" %>
|
||||||
|
<c:set var="pageTitle">대출목록</c:set>
|
||||||
|
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>${pageTitle}</title>
|
||||||
|
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||||
|
|
||||||
|
<script type="text/javaScript" language="javascript">
|
||||||
|
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<!-- javascript warning tag -->
|
||||||
|
<noscript class="noScriptTitle"><spring:message code="common.noScriptTitle.msg" /></noscript>
|
||||||
|
<form
|
||||||
|
action="${pageContext.request.contextPath}/sample/listRentItem.do"
|
||||||
|
method="post">
|
||||||
|
|
||||||
|
<div class="wTableFrm">
|
||||||
|
<!-- 타이틀 -->
|
||||||
|
<h2>${pageTitle}</h2>
|
||||||
|
|
||||||
|
<div style="clear:both;">Server Protocol : ${serverProtocol}</div>
|
||||||
|
<div style="clear:both;">Server IP : ${serverIp}</div>
|
||||||
|
<div style="clear:both;">Server PORT : ${serverPort}</div>
|
||||||
|
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
|
||||||
|
rows : <input name="rows" id="rows" value="10" /> <br />
|
||||||
|
page : <input name="page" id="page" value="1" /> <br />
|
||||||
|
mngOrgCd : <input name="mngOrgCd" id="mngOrgCd" value="KCCF" /> <br />
|
||||||
|
mbInfoId : <input name="mbInfoId" id="mbInfoId" value="BDCCAF34CF8AA365C660ADB121CE6741" /> <br />
|
||||||
|
--------------------------------------------------------------------------
|
||||||
|
<br />
|
||||||
|
resultCode : <input name="resultCode" id="resultCode" value="${resultCode}" /> <br />
|
||||||
|
resultMessage : <input name="resultCode" id="resultCode" value="${resultMessage}" /> <br />
|
||||||
|
totPages : <input name="info.name" id="info.name" value="${info.totPages}" /> <br />
|
||||||
|
records : <input name="info.name" id="info.name" value="${info.records}" /> <br />
|
||||||
|
list : <input name=""list"" id="list" value="${list}" /> <br />
|
||||||
|
<c:forEach var="record" items="${list }">
|
||||||
|
> ----------------------------------------------------------- <br />
|
||||||
|
> mngOrgCd = ${record.mngOrgCd} <br />
|
||||||
|
> operReadRangeCd = ${record.operReadRangeCd} <br />
|
||||||
|
> bookLtRvStatusCd = ${record.bookLtRvStatusCd} <br />
|
||||||
|
> title = ${record.title} <br />
|
||||||
|
> typeCodeNm = ${record.typeCodeNm} <br />
|
||||||
|
> awaiterCnt = ${record.awaiterCnt} <br />
|
||||||
|
> useStatus = ${record.useStatus} <br />
|
||||||
|
</c:forEach>
|
||||||
|
|
||||||
|
<br />
|
||||||
|
|
||||||
|
<div style="clear:both;"></div>
|
||||||
|
|
||||||
|
<input type="submit" id="btnSubmit" name="btnSubmit" value="전송" />
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
28
src/main/webapp/test/testRest.html
Normal file
28
src/main/webapp/test/testRest.html
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
|
||||||
|
<link rel="icon" href="/favicon/favicon.ico" sizes="any"><!-- 32×32 -->
|
||||||
|
<link rel="apple-touch-icon" href="/favicon/apple-touch-icon.png"><!-- 180×180 -->
|
||||||
|
<link rel="manifest" href="/favicon/site.webmanifest">
|
||||||
|
|
||||||
|
|
||||||
|
<link href="/css/nlib.css" rel="stylesheet" type="text/css" />
|
||||||
|
<script src="/js/jquery/jquery.min.js"></script>
|
||||||
|
<script src="/js/nlib.js"></script>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<form action="http://localhost:8088/uac/service/nlib/col/getItemInfo" method="GET">
|
||||||
|
mngOrgCd : <input name="mngOrgCd" id="mngOrgCd" value="SU01" /> <br />
|
||||||
|
masterId : <input name="masterId" id="masterId" value="UR-408A9832D25C42289D9B1FC81FDA8360" /> <br />
|
||||||
|
typeDivCd : <input name="typeDivCd" id="typeDivCd" value="IT_MUSE" /> <br />
|
||||||
|
|
||||||
|
<br />
|
||||||
|
<input type="submit" id="btnSubmit" name="btnSubmit" value="전송" />
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
Loading…
Reference in New Issue
Block a user