1.分页工具类 package com.bw.shop.util; import java.util.List; import com.sun.org.apache.regexp.internal.recompile; public class PageModel { private List list; //结果集 private int totalRecords; //查询记录 private int pageSize; //每页记录条数 private int pageNo; //当前页数
HTML CSS #list{width:680px; height:530px; margin:2px auto; position:relative} #list ul li{float:left;width:220px; height:260px; margin:2px} #list ul li img{width:220px; height:220px} #list ul li p{line-height:22px} #pagecount{width:500px; margin:10px
function pagestart() {//初始化页面,获取公司新闻 $("#pagediv").hide(); $("); var pagesize = $("#pagesize").val(); var requesttye = $("#requesttype").val(); var par = '{"pageIndex":"0","pageSize":"'
IBatis 分页,这里没有使用其他插件,只使用最原始的方法. 输入参数: int currentPage 当前页 int pageSize 每页大小 Hashtable findCondition 查询条件 out int total 返回总数 输出: DataTable 或者 IList<T> 使用了三种分页方式,根据实际情况使用. 我在实际应用中, 第一种返回DataTable,在使用过程中,需要注意它所映射的实体对象名称字段. 第二种方法返回泛型集合,使用的比较顺手,也是习惯使用