Open alkanegit opened 7 years ago
Fixed it:
//if ($table.hasClass('stacktable')) { // return; //} //remove paged temp stackable $(".pagedStackable").remove();
and i rebind after each page like so: $('#searchresults').cardtable({ myClass: 'pagedStackable' });
Added another 'fix' too. If I have a blank row in my table (intentionally) I do not want the header key in my stacked table. So I put a class on the <tr>
like so <tr class="blankkey">
:
Then after
$table.find('>tbody>tr').each(function() {
I add
var trclassname = $(this).attr('class');
and i change this line:
if ($topRow.find('>td,>th').eq(cellIndex).html()){
to this
if ($topRow.find('>td,>th').eq(cellIndex).html() && trclassname != "blankkey"){
seems to work....
Hi.
Is there a way to rebind cardtable?
On initial load I bind like so: $('#searchresults').cardtable();
And on subsequent paging, I call the same again: $('#searchresults').cardtable();
But the cardtable doesn't update the 'hidden' table? Any advice please?