/**
* 获取 Hibernate FirstResult
*/
public int getFirstResult(){
int firstResult = (getPageNo() - 1) * getPageSize();
if (firstResult >= getCount()) {
firstResult = 0;
}
return firstResult;
}
只要传入的pageNo*pageSize大于总条数,就按pageNo=1;获取记录;
2、APP端一直累加pageNo,传入的值越来越大;没有按照pageNo=1的条件,清空页面里的数据;造成不断加载;
@Override public void onResume() { this.articlePresenter.getPageManager().init(); super.onResume(); }
解决