Django-modeltrans

Latest version: v0.7.5

Safety actively analyzes 629723 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 9 of 11

0.3.0

- Adopted [black](https://github.com/ambv/black) code style.
- Removed auto-adding indexes, as it was unpredictable. You must add the `GinIndex` manually like described in the documentation on performance.
- Support dict for `required_languages` argument to `TranslationField`, to allow more fine-grained mapping of field names to required languages.
- `ActiveLanguageMixin` does not use the `<field>_i18n` version of the field, but rather the virtual field with the current active language. This makes sure no fallback values are accidentally saved for another language.

0.2.2

- Hide original field with `ActiveLanguageMixin`.
- Raise an `ValueError` on accessing translated fields on a model fetched with `.defer('i18n')`.
- do not accidentally add `i18n` to __dict__ in Model.create
- Improve handling of explicit PK's and expression rewriting code.
- Add help_text to virtual fields with language=None.

0.2.1

- Dropped support for Django 1.9 and 1.10.
- Used `ugettext_lazy` rather than `ugettext` to fix admin header translation [32](https://github.com/zostera/django-modeltrans/pull/32)
- Removed default value `False` for `Field.editable`, to allow using the translated version of a field in a `ModelForm`.

0.2

Packaged from revision 57.

* ADDED: Support for admin prepopulated_fields.
(resolves issue 21)
* ADDED: Support for admin list_editable.
(thanks carl.j.meyer, resolves issue 20)
* ADDED: Preserve the formfield widget of the translated field.
(thanks piquadrat)
* ADDED: Initial support for django-south.
(thanks andrewgodwin, resolves issue 11)
* ADDED: Support for admin inlines, common and generic.
(resolves issue 12 and issue 18)

* FIXED: Admin form validation errors with empty translated values and
unique=True.
(thanks to adamsc, resolves issue 26)
* FIXED: Mangling of untranslated prepopulated fields.
(thanks to carl.j.meyer, resolves issue 25)
* FIXED: Verbose names of translated fields are not translated.
(thanks to carl.j.meyer, resolves issue 24)
* FIXED: Race condition between model import and translation registration in
production by ensuring that models are registered for translation
before TranslationAdmin runs.
(thanks to carl.j.meyer, resolves issue 19)
* FIXED: Added workaround for swallowed ImportErrors by printing a traceback
explicitly.
(resolves issue 17)
* FIXED: Only print debug statements to stdout if the runserver or
runserver_plus management commands are used.
(resolves issue 16)
* FIXED: Removed print statements so that modeltranslation is usable with
mod_wsgi.
(resolves issue 7)
* FIXED: Broken admin fields and fieldsets.
(thanks simoncelen, resolves issue 9)
* FIXED: Creation of db fields with invalid python language code.
(resolves issue 4)
* FIXED: Tests to run from any project.
(thanks carl.j.meyer, resolves issue 6)
* FIXED: Removed unused dependency to content type which can break syncdb.
(thanks carl.j.meyer, resolves issue 1)

0.2.0

- No annotations are made while ordering anymore, instead, expressions are passed onto the original `order_by()` method.
- Any translated fields used in `Model.Meta.ordering` is transformed into the correct expression with django 2.0 and later (fixes 25).
- `django.contrib.postgres.GinIndex` is added to the `i18n` column if it's supported by the django version used (1.11 and later). It can be disabled with the setting `MODELTRANS_CREATE_GIN`.
- The migration generated from `./manage.py i18n_makemigrations <app>` used to move the data and add a GIN index. This is split into two commands: `./manage.py i18n_makemigrations` and `./manage.py i18n_make_indexes`.
- Added support for `values(**expressions)`` with references to translated fields.
- Added support for translated values in `annotate()`

0.1.2

- Ensure a dynamic mixed `MultilingualQuerySet` can be pickled.
- Add basic support for `Func` in `order_by()`

Page 9 of 11

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.