Using SELECT and RESPONSIVE extension together - Problem with the click event
Using SELECT and RESPONSIVE extension together - Problem with the click event
Hello All !
I am using SELECT and RESPONSIVE extension together in the same table.
The user will be redirected when it clicks on a table row....
grid.on('select', function (e, dt, type, indexes) {
var rowData = grid.rows(indexes).data().toArray();
//console.log('rowData');
//console.log(rowData);
var id = rowData[0][0];
//console.log(id);
onChange(id);
});
The problem is that when I have the RESPONSIVE extension on....
When the user clicks on the "+" icon, to show the row details, it triggers the above "on select" event...
Is there a way to stop that behavior ? Like, if the user clicks on the "+" button the "on select" event is not triggered ... Or someway to check, inside the "on select" function that will stop that function...
Thanks in advance !
Answers
Hi @poetawd ,
You can use
select.selector
to prevent row selection on specific rows. So if you want to avoid the first responsive column, you'd do something likeCheers,
Colin
Awesome ! It kind of works....
But, is that a way to activate that behavior only if the table gets colapsed ?
I tryed this but it did´nt work....
Yes, use a control column. It is hidden if the table isn't collapsed, but shown if it is.
Allan
AWESOME !!!
Many Thanks for the help !!!!