jQuery easyUI 分页(Pagination)用法

YYH_HYY 发布于 2012/04/19 15:34
阅读 9K+
收藏 2

需要知道点击下一页,上一页,首页,尾页可以得到相应数据的代码,以及一些见解!Thanks!

$(function(){
$("#pp").pagination({  
  total:${paging.totalCount},
  pageSize:${paging.pageSize},
  pageNumber:${paging.pageNo},
pageList:[2,4,6],
loading:false,
showPageList:true,
showRefresh:true,
   
  onSelectPage:function(pageNumber, pageSize){
  $(this).pagination('loading');
  $(this).pagination('loaded');
  },
  onChangePageSize:function(pageSize){
  $(this).pagination('loading');
  $(this).pagination('loaded');
  },
  onBeforeRefresh:function(){ 
$(this).pagination('loading'); 
$(this).pagination('loaded');
}

  });

});

加载中
0
antipro
antipro

Properties

Name Type Description Default
total number The total records, which should be setted when pagination is created. 1
pageSize number The page size. 10
pageNumber number Show the page number when pagination is created. 1
pageList array User can change the page size. The pageList property defines how many size can be changed. [10,20,30,50]
loading boolean Defines if data is loading. false
buttons array Defines custom buttons, each button contains two properties:
iconCls: the CSS class which will show a background image
handler: a handler function when button is clicked
null
showPageList boolean Defines if to show page list. true
showRefresh boolean Defines if to show refresh button. true
beforePageText string Show a label before the input component. Page
afterPageText string Show a label after the input component. of {pages}
displayMsg string Display a page information. Displaying {from} to {to} of {total} items

Events

Name Parameters Description
onSelectPage pageNumber, pageSize Fires when user select a new page. callback function contains two parameter:
pageNumber: the new page number
pageSize: the new page size
onBeforeRefresh pageNumber, pageSize Fires before the refresh button is clicked, return false to cancel the refresh action.
onRefresh pageNumber, pageSize Fires after refresh.
onChangePageSize pageSize Fires when user change the page size.
0
YYH_HYY
YYH_HYY

请问做过类似的项目吗 ? 需要详细的代码。

不需要这英文文档,谢谢!

0
chenbing8
chenbing8
请问如果自定义实现refrech刷新数据和分页控制了?
返回顶部
顶部