uchicago-library / library_website

The University of Chicago Library Website
5 stars 5 forks source link

Enable auto-generated sitemap feature on exhibit pages #705

Open bbusenius opened 1 year ago

bbusenius commented 1 year ago

Issue

Some Wagtail page types, such as the StandardPage, have the ability to display an automatically generated sitemap of child pages. An example of such a page is the Using Regenstein page. We need this functionality enabled for ExhibitPages.

The relevant fields for this are theenable_index and display_hierarchical_listing fields defined in the PublicBasePage. They can be edited in the "Widgets" tab of page admin:

image

Additional information:

Since these fields already exist in the ExhibitPage model, they only need to be enabled in the admin, e.g.:

        MultiFieldPanel(
            [
                FieldPanel('enable_index'),
                FieldPanel('display_hierarchical_listing'),
            ],
            heading='Auto-generated Sitemap'
        ),

Since ExhibitPages do not have a "Widgets" tab we will have to decide if we prefer to enable this functionality in one of the existing tabs or if we want to create a "Widgets" tab to maintain consistency with other page types. Talk to @dbietila about this before implementing.