diff options
| author | Tim Graham <timograham@gmail.com> | 2016-08-18 19:48:28 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2016-08-18 21:09:02 -0400 |
| commit | 3342f24ff6f2314c5fc5352aa61c61bd0f43ca75 (patch) | |
| tree | 2e025943beda3d89b6ad1f137a48af7004b58c3f | |
| parent | 21f18e5372fe86090a82b696f3208e56c6a2aa80 (diff) | |
[1.10.x] Fixed #26807 -- Documented how to replicate SubfieldBase's assignment behavior.
Backport of 518eaf1fa2d86dc1b0ba7adba22b30bcc8f3a497 from master
| -rw-r--r-- | docs/releases/1.8.txt | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/docs/releases/1.8.txt b/docs/releases/1.8.txt index d0f115db6e..706d2dc109 100644 --- a/docs/releases/1.8.txt +++ b/docs/releases/1.8.txt @@ -1477,9 +1477,13 @@ It's a legacy option that should no longer be necessary. will be removed in Django 1.10. Historically, it was used to handle fields where type conversion was needed when loading from the database, but it was not used in ``.values()`` calls or in aggregates. It has been replaced with -:meth:`~django.db.models.Field.from_db_value`. Note that the new approach does -not call the :meth:`~django.db.models.Field.to_python` method on assignment -as was the case with ``SubfieldBase``. +:meth:`~django.db.models.Field.from_db_value`. + +The new approach doesn't call the :meth:`~django.db.models.Field.to_python` +method on assignment as was the case with ``SubfieldBase``. If you need that +behavior, reimplement the ``Creator`` class `from Django's source code +<https://github.com/django/django/blob/stable/1.8.x/django/db/models/fields/subclassing.py#L31-L44>`_ +in your project. ``django.utils.checksums`` -------------------------- |
