mirror of
https://github.com/Mottie/tablesorter.git
synced 2024-11-15 23:54:22 +00:00
Ignore child row if it is the first table row
This commit is contained in:
parent
bd332da647
commit
f06a546054
@ -290,7 +290,8 @@
|
|||||||
c = $(b[k].rows[i]);
|
c = $(b[k].rows[i]);
|
||||||
cols = [];
|
cols = [];
|
||||||
// if this is a child row, add it to the last row's children and continue to the next row
|
// if this is a child row, add it to the last row's children and continue to the next row
|
||||||
if (c.hasClass(tc.cssChildRow)) {
|
// ignore child row class, if it is the first row
|
||||||
|
if (c.hasClass(tc.cssChildRow) && i !== 0) {
|
||||||
tc.cache[k].row[tc.cache[k].row.length - 1] = tc.cache[k].row[tc.cache[k].row.length - 1].add(c);
|
tc.cache[k].row[tc.cache[k].row.length - 1] = tc.cache[k].row[tc.cache[k].row.length - 1].add(c);
|
||||||
// add "hasChild" class name to parent row
|
// add "hasChild" class name to parent row
|
||||||
if (!c.prev().hasClass(tc.cssChildRow)) {
|
if (!c.prev().hasClass(tc.cssChildRow)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user