瀏覽代碼

首页限制分类个数

liliang4869 7 年之前
父節點
當前提交
bcba97c1a9
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      src/main/java/com/goafanti/common/controller/WebpageController.java

+ 1 - 0
src/main/java/com/goafanti/common/controller/WebpageController.java

@@ -577,6 +577,7 @@ public class WebpageController extends BaseController {
 		modelview.setViewName("/portal/index");
 	
 		List<JtBusinessCategoryBo> patentCategory=jtBusinessService.getCategoryBoList(1);
+		patentCategory=patentCategory.subList(0, Math.min(3, patentCategory.size()));
 		modelview.addObject("patentCategory",patentCategory);
 		List<JtBusinessProject> jtBusinessProjects=(List<JtBusinessProject>) jtBusinessService.getProjects(null, null, null, 5, 1, 1, 2, 0, 1,0,0,null).getList();
 		for(JtBusinessProject project:jtBusinessProjects) {