diff --git a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/cms/controller/CmsHomePageController.java b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/cms/controller/CmsHomePageController.java index abb632f..e591d7e 100644 --- a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/cms/controller/CmsHomePageController.java +++ b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/cms/controller/CmsHomePageController.java @@ -158,5 +158,20 @@ public class CmsHomePageController /*extends JeecgController getindexnew(CmsArticle cmsArticle, + @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(name = "pageSize", defaultValue = "6") Integer pageSize, + HttpServletRequest req) { + QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(cmsArticle, req.getParameterMap()); + queryWrapper.eq("status", "1"); + queryWrapper.eq("column_id", "1717099205205401602"); + queryWrapper.last("order by publish_time desc"); + Page page = new Page(pageNo, pageSize); + IPage pageList = cmsArticleService.page(page, queryWrapper); + return Result.OK(pageList); + } + }