mirror of https://github.com/django/django.git
Refs #33263 -- Expanded release notes for DeleteView adopting FormMixin.
This commit is contained in:
parent
4816dc9428
commit
2c01ebb4be
|
@ -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