Improve Catalog

* Reduces number of queries needed to calculate the available items (cart date changes now lie in the 800-900 ms range)
* Only refreshes the catalog listings page and not the paginating code, resolving #531 
* Refactor pagination code to make it more readable

aha, I didn't see the secondary definition (this is one reason why I hate JS).

I pulled and your changes fixed the js refresh, yay! :)