Danielson Silva
Danielson Silva

Reputation: 178

Change the limit of rows in a Footable table?

I am doing a query in postgresql that retuns me more than 160 registers. When I try to put the data into a footable table, it only shows 10 rows and nothing more. I tried to add the property in table tag called data-page-size="10000" or data-paging-size="10000" with no luck.

I don't want to put several pages, I just want one page with all the registers.

Upvotes: 2

Views: 2930

Answers (3)

Fury
Fury

Reputation: 4776

Try this :

var numberOfRows = 20;

$('.footable').footable();        
$('.footable').data('page-size', numberOfRows);
$('.footable').trigger('footable_initialized');

OR set the table attribute data-paging-size="20"

<table class="footable" data-paging-size="15">

Upvotes: 1

user10190100
user10190100

Reputation: 11

try it

$(id).footable({pageSize:50});

I find pageSize argument in footable source and it's seem work

Upvotes: 1

user3071284
user3071284

Reputation: 7100

This is the attribute format you want to use:

data-paging-size="1000"

However, it sounds like you want to turn paging off, which you can do during initialization by not including "paging": {"enabled": true} when initializing footable:

// document ready
$(function () {
    $('#myTable').footable({
        // initialization options
    });
});

10 is the default page size. Source

Upvotes: 1

Related Questions