`

jsp中使用valuelist

    博客分类:
  • jsp
JSP 
阅读更多

项目中的程序片断,大家根据自己的情况自己灵活运用,这里只是抛个砖。。。

<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
 ApplicationContext applicationContext = WebApplicationContextUtils.getWebApplicationContext(this.getServletContext());
 ResourceService resourceService = (ResourceService) applicationContext.getBean("resourceService");
 
 Map params = ValueListRequestUtil.getRequestParameterMap(request);   
 String topicId=null;
 if(request.getParameter("topicId")!=null){
  topicId = request.getParameter("topicId");
 }
 ValueList list = resourceService.searchByValueList(Long.valueOf(topicId),params); 
 request.setAttribute("list", list);
%>

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics