Datatables sorting and hidden row issue with alternating colors
Datatables sorting and hidden row issue with alternating colors
eshans
Posts: 11Questions: 3Answers: 0
Hi - is there a way for datatables to ignore hidden rows when sorting so the alternating colors stay the same with hidden rows as they do with ones that are displayed? Thanks for the help. I tried to do this in the code to no avail
rowCallback:function(row, data, index) {
$(row).find('visible:odd').css("background","red") //here to test
$(row).addClass('order-event');
if (!data.orderItemID) {
$(row).addClass('order-only-event');
}
},
drawCallback:function() {
var api = this.api();
filterOrderHistoryTable(api, $orderHistoryFilterSelector.find('.current a'));
}
});
This discussion has been closed.