Skip to main content

extends Django-Modeltranslation and DjangoLDP's serializer and admin to provide i18n capabilities for DjangoLDP models

Project description

# I18nLDPViewSet

I18nLDPViewSet overrides DjangoLDP’s LDPViewSet to provide serialization using the I18nLDPSerializer, instead of the default LDPSerializer

You can activate the custom functionality on your DjangoLDP Model by setting view_set in the Model.Meta: https://git.startinblox.com/djangoldp-packages/djangoldp#view_set

# I18nLDPSerializer

The main functionality of I18n is provided in the serializer, which overrides DjangoLDP’s LDPSerializer to select the activated language content and display this in the context of the response

The language is selected and the data manipulated automatically, based on the request object in the serializer context. A feature to provide the serialization into a language using a setting (without a request object) is TODO

# DjangoLDPI18nAdmin

This admin class simply inherits from DjangoLDPAdmin from DjangoLDP and TranslationAdmin from [Django-Modeltranslation](https://django-modeltranslation.readthedocs.io/en/latest/admin.html) to provide the features from both. It does so without additions

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

djangoldp_i18n-0.0.2.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

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

djangoldp_i18n-0.0.2-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

Details for the file djangoldp_i18n-0.0.2.tar.gz.

File metadata

  • Download URL: djangoldp_i18n-0.0.2.tar.gz
  • Upload date:
  • Size: 6.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.6.10

File hashes

Hashes for djangoldp_i18n-0.0.2.tar.gz
Algorithm Hash digest
SHA256 a87293c4b50438c79c100b3d581a2368006a59b18158305d18233e5cdcf9df9c
MD5 eb1e26a9f75514ac346652365614cf69
BLAKE2b-256 e8c3b02680a5583a4a458c449ddec4e4f230aa7a1475967e21df0fb2b3512fbc

See more details on using hashes here.

File details

Details for the file djangoldp_i18n-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: djangoldp_i18n-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.6.10

File hashes

Hashes for djangoldp_i18n-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a065dabc5397b9f5de7b89138203832645e0af8a3d26334c0267c627caa7ca5a
MD5 1e6f5059ba5a4303c4e88c298ec4a97c
BLAKE2b-256 99622f6971266166ae711e9a889f0ca391ad24751f968a1bb0ce0712ff8a5627

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