DataTables-2.03 Select-2.0.0 nodes is not a function - BUG???
DataTables-2.03 Select-2.0.0 nodes is not a function - BUG???
paul@dmcreative.com
Posts: 27Questions: 5Answers: 0
in Bug reports
Error message generated in Chrome
Uncaught TypeError: type.nodes is not a function:
Upgraded to Datatables 2.0.3 and Select 2.0.0 now the following code that previously worked generates the error message.
resident_table.on( 'select', function ( e, dt, type, indexes ) {
resident_table[type](indexes).nodes().to$().removeClass('warn');
};
The example on the page: https://datatables.net/reference/event/select
Generates the same error.
This question has an accepted answers - jump to answer
Answers
It isn't a function - the fact that it worked before was a bug!
type
is one ofrow
,cell
orcolumn
, and there is norow().nodes()
method. It is eitherrows().nodes()
orrow().node()
- note the pluralisation.The change is easy though - just stick an
s
on the end of types: https://live.datatables.net/jonapudu/1/edit .Allan
Alan,
Problem resolved
Thanks Paul