728x90
반응형
import net.sourceforge.ajaxtags.xml.AjaxXmlBuilder;
@
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
/**
* 최근검색어 결과를 조회한다.
* @param searchVO
* @param model
* @return "model"
* @throws Exception
*/
@RequestMapping(value = "/uss/ion/rsm/listRecentSrchwrdResultSerach.do")
protected ModelAndView egovRecentSrchwrdResultSerachList(
@RequestParam("searchKeyword") String searchKeyword,
RecentSrchwrd recentSrchwrd
) throws Exception {
recentSrchwrd.setQ(searchKeyword);
LOGGER.debug("recentSrchwrd : {}", recentSrchwrd);
ModelAndView model = new ModelAndView(new AjaxXmlView());
RecentSrchwrd recentSrchwrdVO = egovRecentSrchwrdService.selectRecentSrchwrdDetail(recentSrchwrd);
List<?> reusltList = null;
// 사용자검색여부 'Y'인 경우만 검색어 조회
if (recentSrchwrdVO.getSrchwrdManageUseYn().equals("Y")) {
reusltList = egovRecentSrchwrdService.selectRecentSrchwrdResultInquire(recentSrchwrd);
} else { // 2012.11 KISA 보안조치
reusltList = new ArrayList<Object>();
}
AjaxXmlBuilder ajaxXmlBuilder = new AjaxXmlBuilder();
EgovMap emResult = new EgovMap();
for(int i=0;i < reusltList.size(); i++){
emResult = (EgovMap)reusltList.get(i);
ajaxXmlBuilder.addItem((String)emResult.get("recentSrchwrdNm"), (String)emResult.get("recentSrchwrdNm"), false);
}
model.addObject("ajaxXml",ajaxXmlBuilder.toString());
return model;
}
|
cs |
@
728x90
반응형