Harvard-ATG/HarvardCards — pull request #92 by arthurian (2014-10-03 16:29:33+00:00)
Title: Feature/perftweaks

This PR makes some small improvements to the app performance by reducing the total number of database queries on the deck and collection index views. The views themselves were not really tuned for performance, so there were an unnecessary number of database calls in some places.

In particular, the ORM was generating one query per deck to count the total number of cards in the deck. Obviously, that doesn't scale very well, so that ORM query was tweaked so it only needs to generate a single query, not one per deck.