Switching between server side processing and client side

Switching between server side processing and client side

dukwdukw Posts: 2Questions: 1Answers: 0

Hi,

I would like to implement the following behavior:

  1. init datatable with server side processing enabled and ajax source set (init data is fetched from server)
  2. if the displayed data length is equal or less than total data length, server side processing is "switched" off, so sorting operations are done on client side
  3. when update function is called, datatable server side processing is "switched" on (if not already) so the data is fetched from server. go to 2.

Is there a existing solution for that? If not, can anyone suggest possible solution or maybe just an outline of how this should be implemented.

Thank you for your answers in advance!

Answers

  • allanallan Posts: 63,514Questions: 1Answers: 10,472 Site admin

    It is not possible to dynamically switch between client-side and server-side processing at the moment. You need to know up front which one you want to use.

    Allan

  • dukwdukw Posts: 2Questions: 1Answers: 0

    allan, thank you for your answer.

    Yes, I've noticed that there is no such functionality built in the datatables. I was more like hoping that there is a known workaround that I've missed when I was googling this. You know, something like dynamically initializing new datatable every time data gets updated. I was trying to implement something similar, but I'm nothing like frontend guy and things didn't work out well...

This discussion has been closed.