Easyui DataGrid pagination

Source: Internet
Author: User
Paging

Use $. FN. pagination. defaults to reload the default value.

Dependency
  • Link button
User Guide
  1. <Div id = "PP" style = "Background: # efefef; Border: 1px solid # CCC;"> </div>
  1. $ ('# PP'). pagination ({
  2. Total: 2000,
  3. Pagesize: 10
  4. });
Attribute
Name Type Description Default Value
Total (total) Number) Total number of records, which must be set when paging is created. 1
Pagesize (number of records per page) Number) The number of records displayed on each page. 10
Pagenumber (current page number) Number) The current page number is displayed when the page is created. 1
Pagelist (number of records per page that can be selected) Array) You can change the number of records displayed on each page. [10, 20, 30, 50]
Loading (loading or not) Boolean (Boolean) Define whether data is being loaded. False
Buttons (button) Array) Custom buttons. Each button contains two attributes:
Iconcls: CSS class for displaying background images
Handler: A handle function called when a button is clicked.
Null
Showpagelist (display the number of records per page that can be selected) Boolean (Boolean) Determines whether to display the number of records per page that can be selected. True
Showrefresh (display refresh) Boolean (Boolean) Define whether to display the refresh button. True
Beforepagetext (text before the input box) String (string) The symbol displayed before the input box. Page
Afterpagetext (text after the input box) String (string) The symbol displayed after the input box. Of {pages}
Displaymsg (Display Information) String (string) The page information is displayed in the upper-right corner of the plug-in. Displaying {from} to {to} of {total} items
Event
Name Parameters Description
Onselectpage Pagenumber, pagesize The callback function is triggered when you flip pages. The callback function contains two parameters:
Pagenumber: page number of the next page
Pagesize: number of records displayed on the next page
Onbeforerefresh Pagenumber, pagesize Triggered before refreshing. If false is returned, the refreshing is canceled.
Onrefresh Pagenumber, pagesize Triggered after refreshing.
Onchangepagesize Pagesize Triggered when you modify the number of records displayed on each page.
Method
Name Parameters Description
Options None Returns the paging property object.
Loading None The reminder page plug-in is loading.
Loaded None The reminder page plug-in has been loaded.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.