EasyUI Forum
April 29, 2024, 01:46:56 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Datagrid Paging  (Read 7689 times)
dtucker
Newbie
*
Posts: 11


View Profile Email
« on: November 04, 2013, 09:47:02 AM »

I would like to use paging without the server because it seems you have to send pages and all that and I don't want to modify the stored procedures and all that. The other option that seems "cleaner" is client side paging. How would I do this calling an external .PHP page using URL?

This is what I have. How would I modify what I have to make this work:

javascript:
Code:
 $('#dgServiceCategory').datagrid({
                  url: 'Category/SelectCategories.php?orgid='+ _selectedOrganization + "&serviceid=" + rowData.id,
                  pagination:'true',
                  singleSelect:'true',
                  striped:'true',
                  fitColumns:'true'
                 
              });

HTML:
Code:
<table id="dgKeyword" title="Organization Keywords" class="easyui-datagrid" toolbar="#toolbarKeyword" 
>
<thead>
<tr>
<th  data-options="field:'keywordid', width:60" hidden="true">ID</th>
<th data-options="field:'keyword',width:40" >Keyword</th>
</tr>
</thead>
</table>
<div id="toolbarKeyword">
<a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-add" plain="true" onclick="AddKeyword()">New Keyword</a>
<a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-edit" plain="true" onclick="EditKeyword()">Edit Keyword</a>
<a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-remove" plain="true" onclick="DeleteKeyword()">Remove Keyword</a>
</div>

Thanks
Dennis
Logged
stworthy
Administrator
Hero Member
*****
Posts: 3581


View Profile Email
« Reply #1 on: November 05, 2013, 03:23:53 PM »

To enable client side pagination, a possible solution is to override loadFilter function. Please refer to http://www.jeasyui.com/demo/main/index.php?plugin=DataGrid&theme=default&dir=ltr&pitem=Client%20Side%20Pagination
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!