[4.0.x] Refs #33263 -- Expanded release notes for DeleteView adopting FormMixin.
Backport of 2c01ebb4be
from main
This commit is contained in:
parent
499384b6d1
commit
3151daaa6c
|
@ -273,6 +273,10 @@ Generic Views
|
|||
deletion. In addition, this allows ``DeleteView`` to function with
|
||||
:class:`django.contrib.messages.views.SuccessMessageMixin`.
|
||||
|
||||
In accordance with ``FormMixin``, object deletion for POST requests is
|
||||
handled in ``form_valid()``. Custom delete logic in ``delete()`` handlers
|
||||
should be moved to ``form_valid()``, or a shared helper method, as needed.
|
||||
|
||||
Logging
|
||||
~~~~~~~
|
||||
|
||||
|
@ -477,6 +481,14 @@ As a side-effect, running ``makemigrations`` might generate no-op
|
|||
``AlterField`` operations for ``ManyToManyField`` and ``ForeignKey`` fields in
|
||||
some cases.
|
||||
|
||||
``DeleteView`` changes
|
||||
----------------------
|
||||
|
||||
:class:`~django.views.generic.edit.DeleteView` now uses
|
||||
:class:`~django.views.generic.edit.FormMixin` to handle POST requests. As a
|
||||
consequence, any custom deletion logic in ``delete()`` handlers should be
|
||||
moved to ``form_valid()``, or a shared helper method, if required.
|
||||
|
||||
Miscellaneous
|
||||
-------------
|
||||
|
||||
|
|
Loading…
Reference in New Issue