How to change a Datatables "emptyTable" setting after the table has been initialized
How to change a Datatables "emptyTable" setting after the table has been initialized
Hello, I would like to change the "emptyTable" setting dynamically based on how the table is sorted. To be exact, my table holds a number of devices that can be checked out to users. I have 3 custom sorting fields, 'Type', 'Brand', and 'Model'.
Users don't have to sort by any of these fields, and therefore the default "emptyTable" message for no devices being available to check out is "No devices available to be checked out". However, if the user sorts by Type and there are no devices of that certain Type available for checkout the "emptyTable" message should be "No devices of type 'x' are available for checkout."
Is there any way I can do this?