博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
在一个页面加载另一个渲染的页面
阅读量:6938 次
发布时间:2019-06-27

本文共 2374 字,大约阅读时间需要 7 分钟。

 
     
     
       
           
       
     
 

@RequestMapping(value = "similarProduct.json", method = RequestMethod.POST) public String getSimilarProduct(HttpServletRequest request,                                 ModelMap model,                                 @RequestParam(value = "maxResult") int maxResult,                                 @RequestParam(value = "pageNo") int pageNo,                                 @RequestParam(value = "productId", defaultValue = "0") long productId,                                 HttpSession session) {
   Locale currentLocale = getRequestLanguage(session, request);    ProductJsons productJsons = null;    productJsons = extendProductService.moreLikeTag(productId, maxResult, currentLocale.toString());    if (productJsons != null) {
       if (productJsons.getProductJsonList() != null) {
           ArrayList
ids = new ArrayList<>();            for (ProductJson productJson : productJsons.getProductJsonList()) {
               ids.add(productJson.getId());            }            model.addAttribute("ratingMap", getAverageRatingById(ids));            model.addAttribute("checkWish", checkWishById(ids));            model.addAttribute("productJsons", productJsons);        }    }    return "moreLikeThis"; }

moreLikeThis.jsp

<%@ page language="java" pageEncoding="UTF-8" %> <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> <%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %> <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> <%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %> <%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %> <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> 
 
 
     
       
     
 
本文转自wiwi博客51CTO博客,原文链接http://blog.51cto.com/wiwili/1968589如需转载请自行联系原作者
wiwili
你可能感兴趣的文章
蓝桥杯——先进的多说好树遍历
查看>>
Java系列笔记(4) - JVM监控与调优
查看>>
ORACLE工作原理小结
查看>>
LeetCode - Populating Next Right Pointers in Each Node
查看>>
管理团队时,怎样保证一直做正确的事?
查看>>
如果应用程序正在通过 <identity impersonate="true"/> 模拟,则标识将为匿名用户(通常为 IUSR_MACHINENAME)或经过身份验证的请求用户。...
查看>>
表单元素之搭车系
查看>>
mysql+redis
查看>>
[Android]Dagger2Metrics - 测量DI图表初始化的性能(翻译)
查看>>
sublime开启vim模式
查看>>
Rikka with Chess(规律)
查看>>
【设计模式】迭代器模式
查看>>
MATLAB中imshow()和image()
查看>>
Atitit.eclipse git使用
查看>>
JAVA逆向&反混淆-追查Burpsuite的破解原理(转)
查看>>
cocos2dx 3.1从零学习(一)——入门篇(一天学会打飞机)
查看>>
文档批量格式化之word技能
查看>>
C#~异步编程再续~await与async引起的w3wp.exe崩溃
查看>>
c3p0数据库连接池死锁问题
查看>>
SVN版本冲突解决
查看>>