Issue with Infinit scroll and fnDraw
Issue with Infinit scroll and fnDraw
thuthinh
Posts: 2Questions: 0Answers: 0
I have an issue when i use fnDraw with infinite scrolling. The number records at the bottom gets update but the table doesn't get refreshed.
job_type and exclude_item are external filters. This works fine when i dont use infinite scroll. I just want to see what option i have
oTable = $('#table').dataTable(
{
"bJQueryUI": true,
"bFilter": false,
"bSort": false,
"sPaginationType": "full_numbers",
"bProcessing": true,
"bServerSide": true,
"bAutoWidth": false,
"sAjaxSource": URL_TASK + "datatableView",
"sScrollX": "100%",
"bScrollInfinite": true,
"sScrollY": "600px",
"bScrollCollapse": true,
"sServerMethod": "POST",
"fnServerParams": function (aoData) {
aoData.push({ "name": "mode", "value": "rigboard" }, { "name": "mgID", "value": job_type }, { "name": "backlog", "value": exclude_item });
}
});
// External Filter
$('#job-type').on('change', function () {
job_type = $(this).val();
oTable.fnDraw();
});
Thanks in advance
job_type and exclude_item are external filters. This works fine when i dont use infinite scroll. I just want to see what option i have
oTable = $('#table').dataTable(
{
"bJQueryUI": true,
"bFilter": false,
"bSort": false,
"sPaginationType": "full_numbers",
"bProcessing": true,
"bServerSide": true,
"bAutoWidth": false,
"sAjaxSource": URL_TASK + "datatableView",
"sScrollX": "100%",
"bScrollInfinite": true,
"sScrollY": "600px",
"bScrollCollapse": true,
"sServerMethod": "POST",
"fnServerParams": function (aoData) {
aoData.push({ "name": "mode", "value": "rigboard" }, { "name": "mgID", "value": job_type }, { "name": "backlog", "value": exclude_item });
}
});
// External Filter
$('#job-type').on('change', function () {
job_type = $(this).val();
oTable.fnDraw();
});
Thanks in advance
This discussion has been closed.
Replies
Infinite scrolling should be replaced with the functionality provided by Scroller - http://datatables.net/extras/scroller/ .
Allan