backbone.paginator - update per page

I'm using backbone.paginator in my project. I have a dropdown that allows users to select the results per page. Now all I have to do is figure out how to make it work :-)

So far if I do something like this:

this.collection.goTo(page, {
    data: {per_page: newResultsPerPage}

where newResultsPerPage is the number of results the user has selected from the dropdown. The correct number of results come back from the server, but backbone.paginator doesn't correctly update the number of pages. Is there a method I can call that will update / reset the backbone.paginator plugin?


It looks like there is a howManyPer method that I missed in the documentation. I'll leave this question up for anyone else searching for a similar issue in the future.

Need Your Help

Compiling a library for Ruby with SWIG on Mac OS X

c ruby macos osx-snow-leopard swig

I tried to compile the following library and everything went smooth until the last step.

Android NullPointerError on button click

android csv android-fragments nullpointerexception

I'm trying to get one of my fragments to update it's TextView contents by reading a csv file when a button is pressed in another fragment, but I keep getting a FATAL EXCEPTION: main and java.lang.