Add a Processing MessageBox
Add a Processing MessageBox
I have a datatables project that uses serverside processing. It reads from and posts data to a rather slow API (it may take several seconds to perform any I/O operation).
There are html buttons on the page that will read related data to change the contents of the table (this could be a slow call). This makes a call to DataTable().ajax.reload(). I'm also using a datatables button to make an ajax post back to my controller to write data to an API. This is also a slow call.
My question:
I would like to have a "processing" message pop up (something large and noticeable) when the table/page is rendering, or when any of the buttons are pressed. The standard processing message seems to get lost when there is data already rendered in the onscreen table.
Thank you.
This question has an accepted answers - jump to answer
Answers
Checkout this thread about using blockui.js. Here is another with an alternative and example code.
Kevin
Same here! I need this in combination with an alert (using sweetAlert) and - getting rid of the alert with a click - I still need a spinner. One of Kevin's threads is about how I am using busyLoad.
I have some long running Excel reports that are generated server side and then downloaded and displayed as download hyper links in a data table. For some reports this can take several minutes:
The Data Table used is called "reportTable".
"ajaxReloadTbls([reportTable]); " is just a custom function that does an ajax.reload() of the data table with certain parameters.
https://datatables.net/reference/api/ajax.reload()