Skip to content

Instantly share code, notes, and snippets.

@KalobTaulien
Created July 21, 2018 19:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KalobTaulien/c201e4cf33ddc609425aff8448e3ad7b to your computer and use it in GitHub Desktop.
Save KalobTaulien/c201e4cf33ddc609425aff8448e3ad7b to your computer and use it in GitHub Desktop.
Wagtail 2: Removing the Promote and Settings
"""Inside the class example."""
from wagtail.core.models import Page
class YourPage(Page):
"""Your Wagtail Page Type."""
template = "templates/your_page.html"
# Your other Page fields
settings_panels = []
promote_panels = []
"""Outside of the class example."""
from wagtail.core.models import Page
class YourPage(Page):
"""Your Wagtail Page Type."""
template = "templates/your_page.html"
# Your other Page fields
YourPage.promote_panels = [] # Removes the Promote Panel
YourPage.settings_panels = [] # Removes the Settings Panel
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment