1
0
mirror of https://github.com/django/django.git synced 2025-04-10 08:19:39 +00:00

[2.1.x] Documented DeletionMixin.delete().

Backport of 96ea4f875b289aef3372caf7851dabf64347ce8c from master
This commit is contained in:
Claude Paroz 2018-05-24 09:57:10 +02:00 committed by Tim Graham
parent a53d6487b5
commit 3cca2ab2e7

View File

@ -232,6 +232,11 @@ The following mixins are used to construct Django's editing views:
could use ``success_url="/parent/{parent_id}/"`` to redirect to a URL
composed out of the ``parent_id`` field on a model.
.. method:: delete(request, *args, **kwargs)
Retrieves the target object and calls its ``delete()`` method, then
redirects to the success URL.
.. method:: get_success_url()
Returns the url to redirect to when the nominated object has been