How to get row expand click event to avoid row click.
How to get row expand click event to avoid row click.
ppawar
Posts: 2Questions: 1Answers: 0
I have table with clickable row, i'm show details at bottom of table when i click on row. but when i click on expand row image then it conflict row expand button with row click.. . I do not want to fire row click event when i click on row expand button
This discussion has been closed.
Answers
Without seeing what you have and what you are trying to do it will be hard to offer suggestions. Please post a link to your page or a test case replicating the problem so we can help.
https://datatables.net/manual/tech-notes/10#How-to-provide-a-test-case
Kevin
I have below click event on table, which gets fire on table row click. But below event also gets fire when i click on green + and - sign (Expand/Collapse Button) . I want to avoid/by pass below event to get fired when i will click on green + and - sign (Expand/Collapse Button).
Event i 'm having in code:-
$('#datatable-buttons tbody').on('click', 'tr', function (e) {
Maybe you need to use the :not() selector. See if this works:
$('#datatable-buttons tbody').on('click', 'tr:not(.details-control)', function (e) {
Assuming you are using this example.
Kevin