码迷,mamicode.com
首页 > 其他好文 > 详细

showAllArticleForPage

时间:2014-09-03 13:05:26      阅读:208      评论:0      收藏:0      [点我收藏+]

标签:blog   http   io   java   ar   for   2014   art   cti   

public String showAllArticleForPage() throws Exception{
	HttpServletRequest request = ServletActionContext.getRequest();
	String username=(String) ActionContext.getContext().getSession().get("user");
	
	System.out.println("showAllArticleForPage===发表文章和修改文章后跳转的页面 =username="+username);
	String pageIndexS = request.getParameter("pageIndex");
	Integer pageIndex = 1;
	Boolean pcOrmobile=HttpRequestDeviceUtils.isMobileDevice(request);
	System.out.println("pcOrmobile=="+HttpRequestDeviceUtils.isMobileDevice(request));
	if(pcOrmobile){
     return "mobile";
	}
	if(!"".equals(pageIndexS) && pageIndexS != null){
		pageIndex = Integer.parseInt(request.getParameter("pageIndex"));
		request.setAttribute("pageIndex", pageIndex);
	}
	
	//request.setAttribute("pager", articleService.showAllArticleForPageByUsername(username,pageIndex));
	//request.setAttribute("pager", articleService.showAllArticleForPage(pageIndex));
	request.setAttribute("type", "sign");
	return "articlesList";
}

showAllArticleForPage

标签:blog   http   io   java   ar   for   2014   art   cti   

原文地址:http://blog.csdn.net/tfy1332/article/details/39025997

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!