When pipelining data using ajax, how can I refresh table with new data?
When pipelining data using ajax, how can I refresh table with new data?
danielolivasjr
Posts: 1Questions: 1Answers: 0
I'm following the methods described here:
https://datatables.net/examples/server_side/pipeline.html
But, when I want to reload the table with new data, table.ajax.reload(); does not work. I can get it to work, if I remove the pipeline function.
Thanks,
This discussion has been closed.
Answers
settings.clearCache = false before you do the reload
More explicitly, the pipeline code adds the clearCache to the settings object and sets it to false.
$("#example").settings().clearCache = true;
when you hit reload, the pipeline code will set it back to false and make a trip to the server to get fresh data.
look at line 27 in the pipeline code
Best to avoid the settings method if you can! The properties in it are considered to be internal - they can, may and do change between versions.
The pipelining code adds a
clearPipeline()
method to the API so you can simply use:Allan