mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 16:56:36 -04:00
rescheduling ignores dynamic decks
This commit is contained in:
parent
8030b2c969
commit
dc589a5c15
1 changed files with 3 additions and 4 deletions
|
@ -1007,7 +1007,6 @@ your short-term review workload will become."""))
|
||||||
|
|
||||||
def forgetCards(self, ids):
|
def forgetCards(self, ids):
|
||||||
"Put cards at the end of the new queue."
|
"Put cards at the end of the new queue."
|
||||||
print "fixme: make sure this works with dynamic decks, and mv too"
|
|
||||||
self.col.db.execute(
|
self.col.db.execute(
|
||||||
"update cards set type=0,queue=0,ivl=0 where id in "+ids2str(ids))
|
"update cards set type=0,queue=0,ivl=0 where id in "+ids2str(ids))
|
||||||
pmax = self.col.db.scalar(
|
pmax = self.col.db.scalar(
|
||||||
|
@ -1023,9 +1022,9 @@ your short-term review workload will become."""))
|
||||||
for id in ids:
|
for id in ids:
|
||||||
r = random.randint(imin, imax)
|
r = random.randint(imin, imax)
|
||||||
d.append(dict(id=id, due=r+t, ivl=max(1, r), mod=mod))
|
d.append(dict(id=id, due=r+t, ivl=max(1, r), mod=mod))
|
||||||
self.col.db.executemany(
|
self.col.db.executemany("""
|
||||||
"update cards set type=2,queue=2,ivl=:ivl,due=:due where id=:id",
|
update cards set type=2,queue=2,ivl=:ivl,due=:due where id=:id and odid=0""",
|
||||||
d)
|
d)
|
||||||
|
|
||||||
# Repositioning new cards
|
# Repositioning new cards
|
||||||
##########################################################################
|
##########################################################################
|
||||||
|
|
Loading…
Reference in a new issue