https://github.com/codera21/ajaxplugin
jQuery Plugin for making automatic paginated tables
https://github.com/codera21/ajaxplugin
Last synced: 3 months ago
JSON representation
jQuery Plugin for making automatic paginated tables
- Host: GitHub
- URL: https://github.com/codera21/ajaxplugin
- Owner: codera21
- Created: 2018-10-27T15:15:06.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-05-02T04:53:48.000Z (about 6 years ago)
- Last Synced: 2024-12-28T11:41:50.303Z (5 months ago)
- Language: JavaScript
- Homepage:
- Size: 17.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ajaxPlugin
jQuery plugin like datatables
```
$('table').ajaxGrid({
requestType: 'get',
pageSize: 10,
defaultSortExpression: 'gid',
defaultSortOrder: 'desc',
tableHeading: '.table-header',
url: 'Paginate-AjaxGrid/app/api.php',
loadingImage: $('#loading-msg'),
NoRecordsFound: 'No Records Found',
id: 'gid',
rowClass: {class: " my-class"},
addClassToTd: {fields: ['gemail', 'gname'], class: "my-td"}
});```
# refresh grid
```
$('table').trigger("refreshGrid", {filter: document.searchform.filter.value});```
### example
```
postContent: [{
control: $('' +
'' +
' Edit' +
'')
}, {
control: $("" +
" " +
'' +
'' +
' Delete' +
''),
properties: [
{
propertyField: 'input[type=hidden]#ID',
property: 'value',
propertyValue: 'ID'
}
]
}]
```