preXhr doesnt take all the params before it fires
preXhr doesnt take all the params before it fires
shs
Posts: 3Questions: 2Answers: 0
hey guys am creating multiple filters that runs on server side processing and am creating array where am storing the filter values but the problem am getting that only first filter fire on preXHR and i want it to store first all filter values to the array and then do preXhr but it doesnt because my first filter fire and prevent the other to do so on first ajax can someone please help me. this is sample of the code:
This discussion has been closed.
Answers
if (oTable.fnSettings().oFeatures.bServerSide == true) {
console.log('filterdata', filterData);
var settings = oTable.fnSettings();
$(oTable[0]).on('preXhr.dt', function ( e, settings, data ) {
var filter = [];
Object.keys(filterData).forEach(function(key,index) {
filter.push({name: key, value: filterData[key]})