fooplugins / FooTable

jQuery plugin to make HTML tables responsive
https://fooplugins.com/plugins/footable-jquery/
Other
2.13k stars 638 forks source link

Dynamic Paging not working #246

Closed Sushil-Dhiver closed 10 years ago

Sushil-Dhiver commented 10 years ago

Hi Bradvin,

I am trying to set the page size on the table dynamically every time the screen resolution changes but it is not working. I am doing it using Jquery.

I set the dynamic page size on my table using

$('#studiesTable').attr('data-page-size', pageSize);

and then force a redraw

$('table').trigger('footable_setup_paging');
$('.footable').trigger('footable_redraw'); //force a redraw

but it doesn't work. Can you please let me know where I am going wrong?

Sushil-Dhiver commented 10 years ago

Hi Bradvin,

I was able to fix this issue by adding the following 2 lines.

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

i was going through the list of fixed issues and found out that something similar had occurred before. The Paging.htm demo was really helpful.

Thank you very much for this great plugin. this has really helped me a lot to make my application datagrids responsive.

keep up the good work.