Paging set to false => no more data.
Paging set to false => no more data.
Bjorn
Posts: 1Questions: 1Answers: 0
Hi,
I'm new to web development, and recently started using datatables.
I have a table which contains 15 rows. I would like to display all rows at once, without using paging. when I add the option paging = false, my data is no longer displayed, and i simply get the message 'no matching records found'. Without this option the data is displaying fine albeit with pagination.
my datatable looks like this:
dataTable({
"createdRow": function (row, data, index) {
row.id = data[3];
},
"order": [2, 'asc'],
// Do not allow sorting on action button column.
"columnDefs": [
{
"targets": 3,
"orderable": false,
"data": null,
"render": function(data, type, full, meta) {
var editAction = decodeURI('@Url.Action("Edit", new {id = "{0}"})').format(data[3]);
var deleteAction = decodeURI('@Url.Action("Delete", new {id = "{0}"})').format(data[3]);
return '<ul class="list-inline"> <li><a href="' + editAction + '" class="btn btn-primary btn-xs" title="Modify"><i class="fa fa-edit"></i></a></li><li><a href="' + deleteAction + '" class="btn btn-danger btn-xs" title="Delete" data-confirm="#confirmDelete" data-done="deleteDone" data-error="deleteError" data-always="deleteAlways"><i class="fa fa-trash-o"></i></a></li></ul>';
}
}
],
"columns": [
{ "name": "Name1" },
{ "name": "Name2" },
{ "name": "SortOrder", "visible": false}
],
// Do not show the datatables search box, but use our own
"sDom": 'lrti',
"serverSide": true,
"ajax": {
"url": "@Url.Action("JsonGrid")",
"type": "POST"
}
}).rowReordering({ sURL: "/OptionGroups/UpdateOrder", iIndexColumn: 2 });
It is using an HTML table.
What could cause this problem?
Thanks,
This discussion has been closed.