select_all table tools doesn't obey filter selector
select_all table tools doesn't obey filter selector
This may not be a bug, more a feature, but it would be nice if the select_all tabletools button would object the oSelectorOpts filter:applied like "copy to clipboard" and "xls".
I have
{
"sExtends": "select_all", "sButtonText": "Select All", "oSelectorOpts": { "filter": 'applied' }
},
and
{ "sExtends": "copy", "sButtonText": "Copy to clipboard", "oSelectorOpts": { "filter": "applied" } },
I filter down to some number of rows using the inbuilt search. If I select all and then perform a custom button action and use fnGetSelectedData() to look for rows that were selected I find the whole database and not just the rows that were matching the filter.
If select_all would obey oSelectorOpts then that would make select all a heap more useful.
thanks.
This question has an accepted answers - jump to answer
Answers
Hi,
Good point! As a work around, what you could do us use the
rows().nodes()
method which do provide control over the rows being selected, and then feed the result intofnSelect
:TableTools is going to be replaced with a more "modern" library in the next few months, so I'm only really fixing bugs in it at the moment rather than introducing new features. The new library will be better equipped for this kind of thing and for the new DataTables API.
Regards,
Allan
thanks.
Perhaps another work-around would be
fnSelectAll(true)
https://www.datatables.net/extensions/tabletools/api#fnSelectAll
I'd forgotten about that one! Yes, that would work as well.
Allan