We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The last child of a row is getting removed when only one row and one child is available.
I fixed this changing lastIndex to -1, so that when it runs through the first parent it will be set to 0:
if (!p.ajaxUrl) { var i, lastIndex = -1, //change from =0 to =-1 c = table.config, rows = c.$tbodies.eq(0).children("tr"), l = rows.length, sz = p.size === "all" ? p.totalRows : p.size, s = p.page * sz, e = s + sz, last = 0, // for cache indexing j = 0; // size counter p.cacheIndex = []; for (i = 0; i < l; i++) { if (!p.regexFiltered.test(rows[i].className)) { if (j === s && rows[i].className.match(c.cssChildRow)) { // hide child rows @ start of pager (if already visible) rows[i].style.display = "none"; } else { rows[i].style.display = j >= s && j < e ? "" : "none"; if (last !== j && j >= s && j < e) { p.cacheIndex[p.cacheIndex.length] = i; last = j; } // don't count child rows j += rows[i].className.match( c.cssChildRow + "|" + c.selectorRemove.slice(1) ) && !p.countChildRows ? 0 : 1; if ( j === e && rows[i].style.display !== "none" && rows[i].className.match(ts.css.cssHasChild) ) { lastIndex = i; } } } } // add any attached child rows to last row of pager. Fixes part of issue #396 if (lastIndex >= 0 && rows[lastIndex].className.match(ts.css.cssHasChild)) { while (++lastIndex < l && rows[lastIndex].className.match(c.cssChildRow)) { rows[lastIndex].style.display = ""; } } }
The text was updated successfully, but these errors were encountered:
Hi @diegodmendieta!
Sorry for the delay! This is probably related to the issue brought up in #1714. I'll get this fixed in the latest version.
Sorry, something went wrong.
New release is available.
I actually ended up changing last = -1. Please let me know if that doesn't work as expected.
last = -1
No branches or pull requests
The last child of a row is getting removed when only one row and one child is available.
I fixed this changing lastIndex to -1, so that when it runs through the first parent it will be set to 0:
The text was updated successfully, but these errors were encountered: