Skip to main content

Add tags to any model in Django via ModelViewSet

Project description

Django Flexi Tag

Build status Documentation status PyPI PyPI - Django version PyPI - Python version PyPI - License

Flexi tag informs subscribed users via an URL when a specific event occurs.

Installation

Installation using pip:

pip install dj-flexi-tag

flexi-tag package has to be added to INSTALLED_APPS and migrate command has to be run.

INSTALLED_APPS = (
    # other apps here...
    'flexi_tag',
)

After that, need to add to show Tag and TaggedItem in ModelViewSet.

urlpatterns = [
...
    re_path(
        r'^v1/whisperer/',
        include('flexi_tag.urls', namespace='flexi_tag')
    ),
...
]

So, Implementation to the desired ModelViewSet is done as follows;

    from rest_framework import viewsets
    from dj_flexi_tag.utils.viewset import TaggableViewSetMixin


    class DummyTaggableViewSet(viewsets.ModelViewSet, TaggableViewSetMixin):
    ...

Download files

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

Source Distribution

dj-flexi-tag-1.0.0.tar.gz (14.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dj_flexi_tag-1.0.0-py3-none-any.whl (9.6 kB view details)

Uploaded Python 3

File details

Details for the file dj-flexi-tag-1.0.0.tar.gz.

File metadata

  • Download URL: dj-flexi-tag-1.0.0.tar.gz
  • Upload date:
  • Size: 14.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.17

File hashes

Hashes for dj-flexi-tag-1.0.0.tar.gz
Algorithm Hash digest
SHA256 b5897c00a5a2557bfed758d8814dd8c8d968eeeaccdb48f622e252d448726f85
MD5 a16da7da15aef815059e6ecac382736c
BLAKE2b-256 6056109d3597eba3291174ad540785d4a68a013169bcdf47bba813039b1929c8

See more details on using hashes here.

File details

Details for the file dj_flexi_tag-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: dj_flexi_tag-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 9.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.17

File hashes

Hashes for dj_flexi_tag-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f18f874e858e585696b5b8a154232c7b3d37cb80a6284030e3324fae6c517e70
MD5 6354b00166c40cca28b50444249e94be
BLAKE2b-256 fdec37833f2f3a5433c330c137f8fbca8edbdb1a6da1bc7e5eae6c90b7ab5471

See more details on using hashes here.

Supported by

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