May I reset pipelining data of server side processing?

May I reset pipelining data of server side processing?

sjpengsjpeng Posts: 2Questions: 1Answers: 0
edited August 2017 in Free community support

I have references from https://datatables.net/examples/server_side/pipeline.html
the following is my table:

var table = $('#foo').DataTable({
"processing": true,
"serverSide": true,
"dom": 'lrtip',
"lengthMenu": [10, 25, 50, 100],
"order": [[0, 'desc']],
"language": {"url": 'files/' + lang + '.json'},
"columnDefs": [
{"targets": [0], "visible": false, "searchable": false, "width": 0},
{"targets": [1], "visible": true, "searchable": false, "width": '15%'},
{"targets": [2], "visible": true, "searchable": true, "width": '20%'},
{"targets": [3], "visible": true, "searchable": true, "width": '20%'},
{"targets": [4], "visible": true, "searchable": true, "width": '20%'},
{"targets": [5], "visible": true, "searchable": true, "width": '20%'},
], "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('img', nRow).lazyLoadXT();
}
, "ajax": $.fn.dataTable.pipeline({
'url': '/foo/bar',
'data': init,
'pages': 10
})
});

if possible clear table and reset ajax post data and last redraw table?
e.g.

table.DataTable({
"ajax": $.fn.dataTable.pipeline({
'url': '/foo/bar',
'data': new_data,
'pages': 10
})
});

Answers

  • sjpengsjpeng Posts: 2Questions: 1Answers: 0
    edited August 2017

    Ok, here is my solution:

    table.ajax.url(
    $.fn.dataTable.pipeline({
    'url': '/foo/bar',
    'data': new_data,
    'pages': 10
    })
    ).load();

This discussion has been closed.