{ "info": { "author": "David Danier", "author_email": "david.danier@team23.de", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Web Environment", "Framework :: Django", "Framework :: Django :: 1.8", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Natural Language :: English", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.5" ], "description": "django-t10e\n===========\n\n|pypi-badge| |build-status|\n\n.. |build-status| image:: https://travis-ci.org/team23/django_t10e.svg\n :target: https://travis-ci.org/team23/django_t10e\n\n.. |pypi-badge| image:: https://img.shields.io/pypi/v/django-t10e.svg\n :target: https://pypi.python.org/pypi/django-t10e\n\n**django-t10e** is an approach that allows you to translate the contents of\nyour models. **django-t10e** stands for *django-translatable*.\n\nThe concept behind django-t10e is that we have one model instance per\nlanguage. This means one object that is translated into two different languages\nwill be represented by two rows in the model's database table. Every translatable\nmodel has a ``language`` field and a ``translation_set`` field.\n\n``language`` obviously defines the language of each translation and\n``translation_set`` groups the translations of one entity together. All\ninstances with the same ``translation_set`` are considered to be different\ntranslations of the same entity. An entity might be a news article that is\ntranslated into multiple languages..\n\nThe ``translation_set`` field is a ``models.ForeignKey('self')`` field, so it\nalways points to instances of the same model. The first saved instance of one\ntranslation will set this foreign key to its own primary key. The instance to\nwhich all translations of one entity point to (the first translation) is called\nthe base translation.\n\nAn example. Let's assume the following page instances:\n\n- ``Article(id=13, title='I18N is hard', language='en', translation_set=13)``\n- ``Article(id=14, title='Internationalisierung ist schwer', language='de', translation_set=13)``\n- ``Article(id=15, title='La internacionalizaci\u00f3n es dura', language='es', translation_set=13)``\n\nThe article with ``id=13`` is considered the base translation. ``id=14`` is the\ngerman translation of ``id=13``. ``id=15`` is the spanish translation of\n``id=13``. All three make up one translation set for the \"I18N is hard\"\narticle.\n\nThere might also be fields that don't need translation, like date fields etc.\nThese are synced in the translation set. For example: an article model might\nhave a ``pub_date`` field. So all translations in one translation set have the\nsame ``pub_date`` value assigned. When one translation is changed you need to\ncall the ``update_translations()`` method. That will update all other instances\nin the translation set accordingly.\n\nDevelopment\n-----------\n\nInstall the dependencies (including the test dependencies) with::\n\n pip install -r requirements.txt\n\nThen you can run all tests with::\n\n tox\n\n\nChangelog\n=========\n\n0.1.0\n-----\n\n- Initital release.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/team23/django_t10e", "keywords": null, "license": "BSD licence, see LICENSE file", "maintainer": null, "maintainer_email": null, "name": "django-t10e", "package_url": "https://pypi.org/project/django-t10e/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-t10e/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/team23/django_t10e" }, "release_url": "https://pypi.org/project/django-t10e/0.1.0/", "requires_dist": null, "requires_python": null, "summary": "Translatable models using one separate model instance per language translation and syncs non language specific fields.", "version": "0.1.0" }, "last_serial": 4304483, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "adbc53b237855e664621983d7fa21a48", "sha256": "898c37e6a9a46a0642e23f800ce217c873b9ee38b6c2357b8a1c00331f0f7878" }, "downloads": -1, "filename": "django-t10e-0.1.0.tar.gz", "has_sig": false, "md5_digest": "adbc53b237855e664621983d7fa21a48", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11551, "upload_time": "2016-04-05T08:31:49", "url": "https://files.pythonhosted.org/packages/04/e7/1e00f16b3d8af904bd9dacffba3e6f308a354ed43f1b737d9c04d3fe5f0d/django-t10e-0.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "adbc53b237855e664621983d7fa21a48", "sha256": "898c37e6a9a46a0642e23f800ce217c873b9ee38b6c2357b8a1c00331f0f7878" }, "downloads": -1, "filename": "django-t10e-0.1.0.tar.gz", "has_sig": false, "md5_digest": "adbc53b237855e664621983d7fa21a48", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11551, "upload_time": "2016-04-05T08:31:49", "url": "https://files.pythonhosted.org/packages/04/e7/1e00f16b3d8af904bd9dacffba3e6f308a354ed43f1b737d9c04d3fe5f0d/django-t10e-0.1.0.tar.gz" } ] }