Conditional Paging

Conditional Paging

Joshua BarronJoshua Barron Posts: 1Questions: 1Answers: 0

Can conditional paging be made a standard feature of DataTables?

With multiple tables on one page, all initiated/configured by a single javascript function (and dynamically generated), I'd really love to be able to set a row quantity threshold that is required before any one table displays the length and pagination menus.

P.S. If I were getting really fancy, the pagination-threshold variable would also accept a value of -1, which would automatically default to the smallest number in the length menu.

Answers

  • allanallan Posts: 54,709Questions: 1Answers: 8,557 Site admin

    I don't think it is something that is used frequently enough to warrant being included in DataTables core to be honest. I'd prefer to try and keep the core smaller and use plugins more rather than going the monolithic route.

    I do like the idea of being able to set a threshold though. We'll look at adding that ability.

    Allan

  • allanallan Posts: 54,709Questions: 1Answers: 8,557 Site admin

    I was thinking about this a little more - with the paging, is there need for a threshold that is anything other than the page length? You wouldn't want to have a page length of 10, 12 records and a threshold of 20!

    Perhaps you can elaborate on your ideas a little so we can think about how we might implement this?

    Thanks,
    Allan

Sign In or Register to comment.