make sure learn more considers inactive cards

This commit is contained in:
Damien Elmes 2010-12-16 04:28:31 +09:00
parent acb72327b2
commit e4447818ff

View file

@ -524,9 +524,11 @@ order by combinedDue limit %d""" % self.queueLimit, lim=self.dueCutoff)
self.scheduler = "learnMore" self.scheduler = "learnMore"
def _rebuildLearnMoreCount(self): def _rebuildLearnMoreCount(self):
self.newCount = self.s.scalar(""" self.newCount = self.s.scalar(
select count() from cards where type = 2 and combinedDue < :now self.cardLimit(
""", now=self.dueCutoff) "newActive", "newInactive",
"select count(*) from cards c where type = 2 "
"and combinedDue < :lim"), lim=self.dueCutoff)
self.spacedCards = [] self.spacedCards = []
def _updateLearnMoreCountToday(self): def _updateLearnMoreCountToday(self):