springboot分页插件
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</artifactId>
<version>1.2.3</version>
</dependency>
/**
* 分页查询
*
* @param paramVo
* @return
*/
@Override
public List<OwnerOrderSjtListResponseVo> getOwnerOrderSjtListPage(OwnerOrderSjtVo paramVo) {
//使用分页插件,核心代码就这一行
PageHelper.startPage(paramVo.getPageNo(), paramVo.getPageSize());
List<OwnerOrderSjtListResponseVo> sjtListResponseVoList = ownerOrderSjtDao.getOwnerOrderSjtList(paramVo);
return sjtListResponseVoList;
}
原文:https://blog.csdn.net/aiyaya_/article/details/79178984