diff --git a/lacommunaute/forum_conversation/admin.py b/lacommunaute/forum_conversation/admin.py index 46730026..2d12efdd 100644 --- a/lacommunaute/forum_conversation/admin.py +++ b/lacommunaute/forum_conversation/admin.py @@ -6,9 +6,9 @@ class PostAdmin(BasePostAdmin): def get_actions(self, request): - # delete_selected action does not call delete method of the model - # related topic is not update (last_post, posts_count) making - # the website inconsistent + # delete_selected action does not call delete method of the model, so Related topic is not updated. + # When the last post of a topic is deleted, topic.posts_count remains to 1, saying ambiguous information. + # So we remove the delete_selected action to force the user to delete posts one by one. return [] list_filter = BasePostAdmin.list_filter + ("approved",)