From: Jan Szejko Date: Tue, 27 Feb 2018 10:06:42 +0000 (+0100) Subject: set popularity when creating a book X-Git-Url: https://git.mdrn.pl/wolnelektury.git/commitdiff_plain/c56dfc17c204f0b5c84523c14229a779d4c12089?hp=8b8bba0bc15103113d6511b0132114acb7677272 set popularity when creating a book --- diff --git a/src/catalogue/models/book.py b/src/catalogue/models/book.py index 8b85ec718..e5ab5e480 100644 --- a/src/catalogue/models/book.py +++ b/src/catalogue/models/book.py @@ -465,6 +465,7 @@ class Book(models.Model): child.parent_cover_changed() book.save() # update sort_key_author + book.update_popularity() cls.published.send(sender=cls, instance=book) return book