Skip to main content

Django flatpages with advanced features

Project description

Build Maintainability Test Coverage https://codecov.io/gh/snake-soft/django-advanced-pages/branch/main/graph/badge.svg?token=X9MJQJBAEH https://img.shields.io/badge/License-GPLv3-blue.svg

Django advanced pages

With this you can enhance the Django flatpages app by some features.

Features

  • Categorize pages

  • Original Django flatpages are not touched

  • Priorize the pages

  • Categorize the pages

  • Admin loads the enhanced model instead of the flatpages

Installation

Install using pip:

pip install django-advanced-pages

You need to load both, advanced and original pages because this package uses onetoone field to enhance the original Django Flatpages app:

# settings.py
INSTALLED_APPS = [
    # ...
    'django.contrib.flatpages',
    'pages.apps.PagesConfig',
    # ...
]

You can pass the pages to the template like this:

from pages.models import Page, Category
'pages': {
   'company': Page.objects.filter(category=Category.COMPANY),
   'legal': Page.objects.filter(category=Category.LEGAL),
},

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-advanced-pages-0.8.6.tar.gz (18.8 kB view details)

Uploaded Source

Built Distribution

django_advanced_pages-0.8.6-py3-none-any.whl (19.4 kB view details)

Uploaded Python 3

File details

Details for the file django-advanced-pages-0.8.6.tar.gz.

File metadata

  • Download URL: django-advanced-pages-0.8.6.tar.gz
  • Upload date:
  • Size: 18.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.17

File hashes

Hashes for django-advanced-pages-0.8.6.tar.gz
Algorithm Hash digest
SHA256 938bd244db55ba5136f3cfe92e53f4dfd87c9ec9b8cc3115aa84ca43d10739e5
MD5 b5687c13cfe77430bbcbe27f59a28ccf
BLAKE2b-256 beb33ae83e5038e238ef3563e3006e4a9c9f7ed05275d4b486a11ceed9842785

See more details on using hashes here.

File details

Details for the file django_advanced_pages-0.8.6-py3-none-any.whl.

File metadata

File hashes

Hashes for django_advanced_pages-0.8.6-py3-none-any.whl
Algorithm Hash digest
SHA256 e2ef1c9a8196c564e1c40e96abb587eac1e8d6328217890974c180371d68bf61
MD5 a25cf15a557e109ee239b57c40812af9
BLAKE2b-256 fd8a6b1d310fb3c82fb904892dec60bbce48028ca1a9c094fd341bd7357cd9f8

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page