mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 08:46:37 -04:00
add relative overdueness option
This commit is contained in:
parent
b49d52393e
commit
492ed33f4d
2 changed files with 5 additions and 0 deletions
|
@ -36,6 +36,7 @@ DYN_LAPSES = 4
|
|||
DYN_ADDED = 5
|
||||
DYN_DUE = 6
|
||||
DYN_REVADDED = 7
|
||||
DYN_DUEPRIORITY = 8
|
||||
|
||||
# model types
|
||||
MODEL_STD = 0
|
||||
|
@ -83,4 +84,5 @@ def dynOrderLabels():
|
|||
5: _("Order added"),
|
||||
6: _("Order due"),
|
||||
7: _("Latest added first"),
|
||||
8: _("Relative overdueness"),
|
||||
}
|
||||
|
|
|
@ -967,6 +967,9 @@ due = odue, odue = 0, odid = 0, usn = ?, mod = ? where %s""" % lim,
|
|||
t = "n.id desc"
|
||||
elif o == DYN_DUE:
|
||||
t = "c.due"
|
||||
elif o == DYN_DUEPRIORITY:
|
||||
t = "(case when queue=2 and due <= %d then (ivl / cast(%d-due+0.001 as real)) else 10000+due end)" % (
|
||||
self.today, self.today)
|
||||
else:
|
||||
# if we don't understand the term, default to due order
|
||||
t = "c.due"
|
||||
|
|
Loading…
Reference in a new issue