项目重构,用到了pagehelper,但是发现PageHelper.startPage(pageNum,pageSize);分页不起作用,查找问题发现版本有问题。
springboot的版本:
<spring-boot.version>2.5.4</spring-boot.version>
pagehelper的版本:
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper</artifactId>
<version>3.2.1</version>
</dependency>
springboot做了升级。把pagehelper切换成对应的2.0的版本即可。
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</artifactId>
<version>1.2.12</version>
</dependency>
最后
以上就是现实小兔子最近收集整理的关于PageHelper.startPage(pageNum,pageSize)分页不起作用的全部内容,更多相关PageHelper内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复