Quantcast
Channel: DataTables 1.10 — DataTables forums
Viewing all articles
Browse latest Browse all 2364

Child Row - How to select Parent Row

$
0
0

I am using a nested child row for detailed information. I have a need to refresh the data for the parent row, and cannot figure out how to properly select the parent my javascript.

This is the javaScript that runs when a span is clicked within the child row:

// Add event listener for refreshing transaction queue
            $('#table tbody').on('click', 'span.trans-in-queue-lineitem', function () {
                var tr = $(this).closest('tr');
                var tr2 = tr.prev('tr');

                var row = table.row(tr2);
            });

My selector for tr2 is what is giving me trouble.


Viewing all articles
Browse latest Browse all 2364

Trending Articles