Make ProgressUpdate attached to a readthrough

This commit is contained in:
Joel Bradshaw
2020-11-16 23:53:17 -08:00
parent 13229ea937
commit 00b8608a50
2 changed files with 2 additions and 4 deletions

View File

@ -428,12 +428,10 @@ def edit_readthrough(request):
# record the progress update individually
# use default now for date field
progress_update = models.ProgressUpdate(
readthrough.progressupdate_set.create(
user=request.user,
book=readthrough.book,
progress=readthrough.pages_read,
mode=models.ProgressMode.PAGE)
progress_update.save()
return redirect(request.headers.get('Referer', '/'))