파일명 변경 : Collection -> Ris
This commit is contained in:
parent
950cb3eaaf
commit
1eb1fd7141
@ -6,7 +6,7 @@ import java.util.List;
|
||||
import nlib.restful.service.DataApiReqVO;
|
||||
import nlib.restful.service.DataApiResVO;
|
||||
|
||||
public interface CollectionService
|
||||
public interface RisService
|
||||
{
|
||||
public DataApiResVO listItems(DataApiReqVO reqVO);
|
||||
|
||||
@ -26,10 +26,10 @@ import nlib.cmm.service.NotificationVO;
|
||||
import nlib.cmm.service.NlibProperty;
|
||||
import nlib.user.service.NlibLoginVO;
|
||||
import nlib.util.StringUtil;
|
||||
@Repository("collectionDAO")
|
||||
public class CollectionDAO extends EgovComAbstractDAO
|
||||
@Repository("risDAO")
|
||||
public class RisDAO extends EgovComAbstractDAO
|
||||
{
|
||||
private static final Logger log = LoggerFactory.getLogger(CollectionDAO.class);
|
||||
private static final Logger log = LoggerFactory.getLogger(RisDAO.class);
|
||||
|
||||
/*
|
||||
*//**
|
||||
@ -9,20 +9,20 @@ import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import nlib.col.service.CollectionService;
|
||||
import nlib.col.service.RisService;
|
||||
import nlib.col.service.CollectionVO;
|
||||
import nlib.col.service.DeptVO;
|
||||
import nlib.col.service.RisVO;
|
||||
import nlib.restful.service.DataApiReqVO;
|
||||
import nlib.restful.service.DataApiResVO;
|
||||
|
||||
@Service("collectionService")
|
||||
public class CollectionServiceImpl implements CollectionService
|
||||
@Service("risService")
|
||||
public class RisServiceImpl implements RisService
|
||||
{
|
||||
private static final Logger log = LoggerFactory.getLogger(CollectionServiceImpl.class);
|
||||
private static final Logger log = LoggerFactory.getLogger(RisServiceImpl.class);
|
||||
|
||||
@Resource(name = "collectionDAO")
|
||||
private CollectionDAO collectionDAO;
|
||||
@Resource(name = "risDAO")
|
||||
private RisDAO risDAO;
|
||||
|
||||
/*
|
||||
* 소장자료 목록을 조회한다.
|
||||
@ -31,7 +31,7 @@ public class CollectionServiceImpl implements CollectionService
|
||||
* @see nlib.col.service.CollectionService#listItems(nlib.restful.service.DataApiReqVO)
|
||||
*/
|
||||
public DataApiResVO listItems(DataApiReqVO reqVO) {
|
||||
return ((CollectionService) collectionDAO).listItems(reqVO);
|
||||
return ((RisService) risDAO).listItems(reqVO);
|
||||
}
|
||||
|
||||
public DataApiResVO insertInterest(DataApiReqVO reqVO) {
|
||||
@ -56,7 +56,7 @@ public class CollectionServiceImpl implements CollectionService
|
||||
* @see nlib.col.service.CollectionService#selectItemInfo(nlib.restful.service.DataApiReqVO)
|
||||
*/
|
||||
public DataApiResVO selectItemInfo(DataApiReqVO reqVO) {
|
||||
return ((CollectionService) collectionDAO).selectItemInfo(reqVO);
|
||||
return ((RisService) risDAO).selectItemInfo(reqVO);
|
||||
}
|
||||
|
||||
/*
|
||||
@ -65,7 +65,7 @@ public class CollectionServiceImpl implements CollectionService
|
||||
* @see nlib.col.service.CollectionService#selectRisInfo(nlib.col.service.CollectionVO)
|
||||
*/
|
||||
public RisVO selectRisInfo(RisVO vo) {
|
||||
return collectionDAO.selectRisInfo(vo);
|
||||
return risDAO.selectRisInfo(vo);
|
||||
}
|
||||
|
||||
/*
|
||||
@ -74,7 +74,7 @@ public class CollectionServiceImpl implements CollectionService
|
||||
* @see nlib.col.service.CollectionService#selectOrgList()
|
||||
*/
|
||||
public List<DeptVO> selectOrgList() {
|
||||
return collectionDAO.selectOrgList();
|
||||
return risDAO.selectOrgList();
|
||||
}
|
||||
|
||||
/*
|
||||
@ -83,7 +83,7 @@ public class CollectionServiceImpl implements CollectionService
|
||||
* @see nlib.col.service.CollectionService#listItems(nlib.col.service.CollectionVO)
|
||||
*/
|
||||
public List<CollectionVO> listItems(CollectionVO searchCollectionVO) {
|
||||
return collectionDAO.listItems(searchCollectionVO);
|
||||
return risDAO.listItems(searchCollectionVO);
|
||||
}
|
||||
|
||||
/*
|
||||
@ -92,6 +92,6 @@ public class CollectionServiceImpl implements CollectionService
|
||||
* @see nlib.col.service.CollectionService#countListItems(nlib.col.service.CollectionVO)
|
||||
*/
|
||||
public int countListItems(CollectionVO searchCollectionVO) {
|
||||
return collectionDAO.countListItems(searchCollectionVO);
|
||||
return risDAO.countListItems(searchCollectionVO);
|
||||
}
|
||||
}
|
||||
@ -23,7 +23,7 @@ import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import nlib.cmm.NlibCommonController;
|
||||
import nlib.cmm.service.CodeService;
|
||||
import nlib.cmm.service.NlibProperty;
|
||||
import nlib.col.service.CollectionService;
|
||||
import nlib.col.service.RisService;
|
||||
import nlib.col.service.CollectionVO;
|
||||
import nlib.col.service.DeptVO;
|
||||
import nlib.col.service.InterestService;
|
||||
@ -62,7 +62,7 @@ public class InterestController extends NlibCommonController
|
||||
private InterestService interestService;
|
||||
|
||||
@Resource(name = "collectionService")
|
||||
private CollectionService collectionService;
|
||||
private RisService collectionService;
|
||||
|
||||
@Resource(name = "codeService")
|
||||
private CodeService codeService;
|
||||
|
||||
@ -31,7 +31,7 @@ import nlib.cmm.NlibCommonController;
|
||||
import nlib.cmm.service.CodeService;
|
||||
import nlib.cmm.service.NlibProperty;
|
||||
import nlib.cmm.service.PagingVO;
|
||||
import nlib.col.service.CollectionService;
|
||||
import nlib.col.service.RisService;
|
||||
import nlib.col.service.CollectionVO;
|
||||
import nlib.col.service.DeptVO;
|
||||
import nlib.col.service.InterestService;
|
||||
@ -46,16 +46,16 @@ import nlib.util.StringUtil;
|
||||
*
|
||||
*/
|
||||
@Controller
|
||||
public class CollectionController extends NlibCommonController
|
||||
public class RisController extends NlibCommonController
|
||||
{
|
||||
private static final Logger log = LoggerFactory.getLogger(CollectionController.class);
|
||||
private static final Logger log = LoggerFactory.getLogger(RisController.class);
|
||||
static final String DEFUALT_PAGE_SIZE = NlibProperty.getProperty("list.paging.page.size");
|
||||
|
||||
@Resource(name = "codeService")
|
||||
private CodeService codeService;
|
||||
|
||||
@Resource(name="collectionService")
|
||||
private CollectionService collectionService;
|
||||
@Resource(name="risService")
|
||||
private RisService risService;
|
||||
|
||||
@Resource(name = "interestService")
|
||||
private InterestService interestService;
|
||||
@ -66,38 +66,38 @@ public class CollectionController extends NlibCommonController
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping("/collection/listItems.do")
|
||||
public String listItems(HttpServletRequest req, Authentication authentication, @RequestParam Map<String, String> paramMap, ModelMap model) throws Exception {
|
||||
String searchKeyword = paramMap.get("searchKeyword");
|
||||
String pageIndex = StringUtil.getString(paramMap.get("pageIndex"), "1");
|
||||
String pageSize = StringUtil.getString(paramMap.get("pageSize") , DEFUALT_PAGE_SIZE);
|
||||
List<DeptVO> vo = new ArrayList();
|
||||
|
||||
// 페이징 사이즈 코드 목록 조회 (DB방식으로 변경 2021.08.06 KNKIM)
|
||||
List<HashMap<String,String>> pageSizeCodes = codeService.listCodes("PAGE_SIZE_OPTION");
|
||||
|
||||
// 자료유형 코드 목록 조회
|
||||
List<HashMap<String,String>> masterType = codeService.listCodes("MASTER_TYPE_DIV_CD");
|
||||
List<HashMap<String,String>> dtlsType = codeService.listCodes("DTLS_TYPE_DIV_CD");
|
||||
|
||||
//주제분야 목록 조회
|
||||
List<HashMap<String,String>> clsf = codeService.listCtClsfs();
|
||||
|
||||
//문화원 목록 조회
|
||||
vo = collectionService.selectOrgList();
|
||||
|
||||
// 반환 정보
|
||||
model.addAttribute("pageIndex" , pageIndex);
|
||||
model.addAttribute("pageSize" , pageSize);
|
||||
model.addAttribute("searchKeyword", searchKeyword);
|
||||
model.addAttribute("pageSizeCodes", pageSizeCodes);
|
||||
model.addAttribute("masterType", masterType);
|
||||
model.addAttribute("dtlsType", dtlsType);
|
||||
model.addAttribute("masterClsf", clsf);
|
||||
model.addAttribute("dtlsClsf", clsf);
|
||||
model.addAttribute("orgList",vo);
|
||||
return "nlib/collection/listItems";
|
||||
}
|
||||
// @RequestMapping("/collection/listItems.do")
|
||||
// public String listItems(HttpServletRequest req, Authentication authentication, @RequestParam Map<String, String> paramMap, ModelMap model) throws Exception {
|
||||
// String searchKeyword = paramMap.get("searchKeyword");
|
||||
// String pageIndex = StringUtil.getString(paramMap.get("pageIndex"), "1");
|
||||
// String pageSize = StringUtil.getString(paramMap.get("pageSize") , DEFUALT_PAGE_SIZE);
|
||||
// List<DeptVO> vo = new ArrayList();
|
||||
//
|
||||
// // 페이징 사이즈 코드 목록 조회 (DB방식으로 변경 2021.08.06 KNKIM)
|
||||
// List<HashMap<String,String>> pageSizeCodes = codeService.listCodes("PAGE_SIZE_OPTION");
|
||||
//
|
||||
// // 자료유형 코드 목록 조회
|
||||
// List<HashMap<String,String>> masterType = codeService.listCodes("MASTER_TYPE_DIV_CD");
|
||||
// List<HashMap<String,String>> dtlsType = codeService.listCodes("DTLS_TYPE_DIV_CD");
|
||||
//
|
||||
// //주제분야 목록 조회
|
||||
// List<HashMap<String,String>> clsf = codeService.listCtClsfs();
|
||||
//
|
||||
// //문화원 목록 조회
|
||||
// vo = risService.selectOrgList();
|
||||
//
|
||||
// // 반환 정보
|
||||
// model.addAttribute("pageIndex" , pageIndex);
|
||||
// model.addAttribute("pageSize" , pageSize);
|
||||
// model.addAttribute("searchKeyword", searchKeyword);
|
||||
// model.addAttribute("pageSizeCodes", pageSizeCodes);
|
||||
// model.addAttribute("masterType", masterType);
|
||||
// model.addAttribute("dtlsType", dtlsType);
|
||||
// model.addAttribute("masterClsf", clsf);
|
||||
// model.addAttribute("dtlsClsf", clsf);
|
||||
// model.addAttribute("orgList",vo);
|
||||
// return "nlib/collection/listItems";
|
||||
// }
|
||||
|
||||
/**
|
||||
* 소장자료를 조회한다.
|
||||
@ -105,55 +105,55 @@ public class CollectionController extends NlibCommonController
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value="/collection/listItemsAjax.do")
|
||||
public ResponseEntity<String> listItemsAjax(HttpServletRequest req,
|
||||
Authentication authentication, @RequestBody CollectionVO searchCollectionVO) {
|
||||
|
||||
//String searchKeyword = paramMap.get("searchKeyword");
|
||||
if(searchCollectionVO.getPageIndex() < 1) searchCollectionVO.setPageIndex(1);
|
||||
if(searchCollectionVO.getPageSize() < 1) searchCollectionVO.setPageSize(DEFUALT_PAGE_SIZE);
|
||||
|
||||
|
||||
int totalCount= 0;
|
||||
//사용자 정보를 가져온다.
|
||||
NlibLoginVO loginVO = getNlibLoginVO(authentication);
|
||||
|
||||
searchCollectionVO.setPageStart(searchCollectionVO.getPageIndex(), searchCollectionVO.getPageSize());
|
||||
List<CollectionVO> List = new ArrayList();
|
||||
|
||||
// 요청
|
||||
List = collectionService.listItems(searchCollectionVO);
|
||||
totalCount = collectionService.countListItems(searchCollectionVO);
|
||||
|
||||
PagingVO pageVO = new PagingVO();
|
||||
pageVO.setPagingVO(totalCount, searchCollectionVO.getPageIndex(), searchCollectionVO.getPageSize());
|
||||
|
||||
//-------------------------------
|
||||
// REQ VO 구성
|
||||
//-------------------------------
|
||||
/*DataApiReqVO reqVO = new DataApiReqVO();
|
||||
reqVO.setPageIndex(pageIndex);
|
||||
reqVO.setPageSize(pageSize);
|
||||
reqVO.putInfoItem("searchKeyword", searchKeyword);*/
|
||||
|
||||
// 요청
|
||||
//DataApiResVO resVO = collectionService.listItems(reqVO);
|
||||
|
||||
//-------------------------------
|
||||
// JSON변환 응답 처리
|
||||
//-------------------------------
|
||||
// JS-GRID 페이징 처리를 포함한 응답값 처리
|
||||
// {data: [{...}],
|
||||
// itemsCount: 255
|
||||
// @RequestMapping(value="/collection/listItemsAjax.do")
|
||||
// public ResponseEntity<String> listItemsAjax(HttpServletRequest req,
|
||||
// Authentication authentication, @RequestBody CollectionVO searchCollectionVO) {
|
||||
//
|
||||
// //String searchKeyword = paramMap.get("searchKeyword");
|
||||
// if(searchCollectionVO.getPageIndex() < 1) searchCollectionVO.setPageIndex(1);
|
||||
// if(searchCollectionVO.getPageSize() < 1) searchCollectionVO.setPageSize(DEFUALT_PAGE_SIZE);
|
||||
//
|
||||
//
|
||||
// int totalCount= 0;
|
||||
// //사용자 정보를 가져온다.
|
||||
// NlibLoginVO loginVO = getNlibLoginVO(authentication);
|
||||
//
|
||||
// searchCollectionVO.setPageStart(searchCollectionVO.getPageIndex(), searchCollectionVO.getPageSize());
|
||||
// List<CollectionVO> List = new ArrayList();
|
||||
//
|
||||
// // 요청
|
||||
// List = risService.listItems(searchCollectionVO);
|
||||
// totalCount = risService.countListItems(searchCollectionVO);
|
||||
//
|
||||
// PagingVO pageVO = new PagingVO();
|
||||
// pageVO.setPagingVO(totalCount, searchCollectionVO.getPageIndex(), searchCollectionVO.getPageSize());
|
||||
//
|
||||
// //-------------------------------
|
||||
// // REQ VO 구성
|
||||
// //-------------------------------
|
||||
// /*DataApiReqVO reqVO = new DataApiReqVO();
|
||||
// reqVO.setPageIndex(pageIndex);
|
||||
// reqVO.setPageSize(pageSize);
|
||||
// reqVO.putInfoItem("searchKeyword", searchKeyword);*/
|
||||
//
|
||||
// // 요청
|
||||
// //DataApiResVO resVO = collectionService.listItems(reqVO);
|
||||
//
|
||||
// //-------------------------------
|
||||
// // JSON변환 응답 처리
|
||||
// //-------------------------------
|
||||
// // JS-GRID 페이징 처리를 포함한 응답값 처리
|
||||
// // {data: [{...}],
|
||||
// // itemsCount: 255
|
||||
// // }
|
||||
// HashMap<String, Object> retMap = new HashMap<String, Object>();
|
||||
// /*retMap.put("data", resVO.getList(DataApiVO.XML_EL_NAME_RECORD));
|
||||
// retMap.put("itemsCount", resVO.getRecordTotCount());*/
|
||||
// retMap.put("data", List);
|
||||
// retMap.put("pageVO", pageVO);
|
||||
//
|
||||
// return makeResponseEntityJson(retMap);
|
||||
// }
|
||||
HashMap<String, Object> retMap = new HashMap<String, Object>();
|
||||
/*retMap.put("data", resVO.getList(DataApiVO.XML_EL_NAME_RECORD));
|
||||
retMap.put("itemsCount", resVO.getRecordTotCount());*/
|
||||
retMap.put("data", List);
|
||||
retMap.put("pageVO", pageVO);
|
||||
|
||||
return makeResponseEntityJson(retMap);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
@ -161,12 +161,12 @@ public class CollectionController extends NlibCommonController
|
||||
* @param vo
|
||||
* @throws IOException
|
||||
*/
|
||||
@RequestMapping(value="/collection/risDownload.do")
|
||||
@RequestMapping(value="/ris/risDownload.do")
|
||||
public void risDownload(HttpServletRequest request,HttpServletResponse response) throws IOException {
|
||||
RisVO vo = new RisVO();
|
||||
vo.setMasterId(request.getParameter("masterId"));
|
||||
|
||||
vo = collectionService.selectRisInfo(vo);
|
||||
vo = risService.selectRisInfo(vo);
|
||||
|
||||
response.setContentType("text/plain");
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?><!--Converted at: Wed May 11 15:49:38 KST 2016-->
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="CollectionDAO">
|
||||
<mapper namespace="RisDAO">
|
||||
|
||||
<select id="selectRisInfo" parameterType="RisVO" resultType="RisVO">
|
||||
/* CollectionDAO.selectRisInfo RIS다운로드를 위한 자료 정보 조회 */
|
||||
Loading…
Reference in New Issue
Block a user