feat(pages.py): add EventIndexPage
This commit is contained in:
@@ -56,6 +56,10 @@ class CourseIndexPage(Page):
|
|||||||
return context
|
return context
|
||||||
|
|
||||||
|
|
||||||
|
class EventIndexPage(Page):
|
||||||
|
subpage_types = ["home.EventPage"]
|
||||||
|
|
||||||
|
|
||||||
class BlogPage(Page):
|
class BlogPage(Page):
|
||||||
author = models.CharField(max_length=255)
|
author = models.CharField(max_length=255)
|
||||||
image = models.ForeignKey(
|
image = models.ForeignKey(
|
||||||
@@ -309,6 +313,8 @@ class EventPage(Page):
|
|||||||
help_text="Select users who will be listed as hosts of this event.",
|
help_text="Select users who will be listed as hosts of this event.",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
parent_page_types = ["home.EventIndexPage"]
|
||||||
|
|
||||||
def get_context(self, request):
|
def get_context(self, request):
|
||||||
context = super().get_context(request)
|
context = super().get_context(request)
|
||||||
# Occurrence-specific context should be handled in views/templates
|
# Occurrence-specific context should be handled in views/templates
|
||||||
|
|||||||
Reference in New Issue
Block a user