From 18814ead9349fd02ec05e1785a425eec114819bc Mon Sep 17 00:00:00 2001 From: Alex Morega Date: Wed, 8 May 2024 00:36:51 +0300 Subject: [PATCH] fix: BlogPage may only be created under BlogIndexPage (#401) --- ietf/blog/models.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ietf/blog/models.py b/ietf/blog/models.py index 5cd210cf..2c0a1a5d 100644 --- a/ietf/blog/models.py +++ b/ietf/blog/models.py @@ -164,6 +164,11 @@ class BlogPage(Page, BibliographyMixin, PromoteMixin): ) CONTENT_FIELD_MAP = {"body": "prepared_body"} + parent_page_types = [ + "blog.BlogIndexPage", + ] + subpage_types = [] + def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) self.filter_topic = None