card rescheduling needs to bump mod time and usn

This commit is contained in:
Damien Elmes 2012-03-13 22:28:25 +09:00
parent 056e146696
commit 17891edb72

View file

@ -1025,9 +1025,11 @@ your short-term review workload will become."""))
mod = intTime() mod = intTime()
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,
usn=self.col.usn()))
self.col.db.executemany(""" self.col.db.executemany("""
update cards set type=2,queue=2,ivl=:ivl,due=:due where id=:id and odid=0""", update cards set type=2,queue=2,ivl=:ivl,due=:due,
usn=:usn, mod=:mod where id=:id and odid=0""",
d) d)
# Repositioning new cards # Repositioning new cards