Wagtail pages

models

class geniza.pages.models.AccordionBlock(*args, **kwargs)[source]

Accordion StructBlock for collapsible sections and/or FAQs

class geniza.pages.models.BodyContentBlock(*args, **kwargs)[source]

Common set of content blocks for content pages.

class geniza.pages.models.CaptionedImageBlock(*args, **kwargs)[source]

StructBlock for an image with alternative text and optional formatted caption, so that both caption and alternative text can be context-specific.

class geniza.pages.models.ContainerPage(*args, **kwargs)[source]

An empty Page type that has ContentPage instances as its subpages.

exception DoesNotExist
exception MultipleObjectsReturned
serve(request)[source]

override serve method to redirect to parent page instead of rendering

class geniza.pages.models.ContentPage(*args, **kwargs)[source]

A simple Page type for content pages.

exception DoesNotExist
exception MultipleObjectsReturned
get_context(request)[source]

add page type to context

class geniza.pages.models.HomePage(*args, **kwargs)[source]

wagtail.core.models.Page model for Geniza home page.

exception DoesNotExist
exception MultipleObjectsReturned
get_context(request)[source]

add page type to context

class geniza.pages.models.SVGImageBlock(*args, **kwargs)[source]

StructBlock for an SVG image with alternative text and optional formatted caption. Separate from CaptionedImageBlock because Wagtail image handling does not work with SVG.

manage commands

class geniza.pages.management.commands.bootstrap_content.Command(stdout=None, stderr=None, no_color=False, force_color=False)[source]
add_arguments(parser)[source]

Entry point for subclassed commands to add custom arguments.

generate_test_content_page()[source]

Create a test content page from fixture

handle(*args, **options)[source]

Bootstrap content for Geniza public project site. NOTE: Not idempotent. Will recreate pages if they already exist.