New to JQuery Datatables and I'm trying to include two Excel buttons. One that exports the current table, and then another that makes a call to the controller for a completely different report. I've got the current table export working, but stumped as to how to include this second button.
If you already have a controller you want the second button to call (which it sounds like you do), then you should just have one Excel button and once custom button that you can label whatever you want (and have call whatever controller you want). The syntax for a custom button looks like this:
action function, you can use the
dt.data(). You can then make a custom ajax call to your other controller with that data.
As a concluding note, see that you can essentially have a button do whatever you want, but if you're using a button that doesn't have built in functionality like the
excel button, then you will have to implement the functionality yourself.
See this documentation page if you want to see what
config are used for if you ever want more complicated custom buttons.