Help saving state of custom filter
Help saving state of custom filter
Mrb1972
Posts: 1Questions: 1Answers: 0
Hi, I have created a button which when clicked only shows the rows with a value greater than 0, that all seems to work fine, but is it possible to save the state of this filter? Any advice would be welcome.
`buttons: [
{
text: "In Stock Only",
action: function() {
$.fn.dataTable.ext.search.push(
function( settings, data, dataIndex ) {
return parseFloat(data[3])>0
? true
: false
}
);
table.draw();
$.fn.dataTable.ext.search.pop();
},
},`
This discussion has been closed.
Answers
Hi @Mrb1972 ,
This here looks like it's doing what you want - hopefully that'll do the trick for you,
Cheers,
Colin