summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorMarkus Amalthea Magnuson <markus.magnuson@gmail.com>2016-04-03 16:50:01 +0200
committerTim Graham <timograham@gmail.com>2016-04-20 11:31:44 -0400
commit08cd6a0e56bac04e322388e7059072ad98db303c (patch)
tree615d175fcf55f2d1ebe02a5895aacb1104b7ec03 /docs
parentcb65e62c84dd8f6b412151e81cf665975143d397 (diff)
Fixed #16327 -- Redirected "Save as new" to change view instead of the changelist.
Diffstat (limited to 'docs')
-rw-r--r--docs/ref/contrib/admin/index.txt10
-rw-r--r--docs/releases/1.10.txt7
2 files changed, 17 insertions, 0 deletions
diff --git a/docs/ref/contrib/admin/index.txt b/docs/ref/contrib/admin/index.txt
index 284d6aa62d..4f5cc22de1 100644
--- a/docs/ref/contrib/admin/index.txt
+++ b/docs/ref/contrib/admin/index.txt
@@ -1146,6 +1146,16 @@ subclass::
By default, ``save_as`` is set to ``False``.
+.. attribute:: ModelAdmin.save_as_continue
+
+ .. versionadded:: 1.10
+
+ When :attr:`save_as=True <save_as>`, the default redirect after saving the
+ new object is to the change view for that object. If you set
+ ``save_as_continue=False``, the redirect will be to the changelist view.
+
+ By default, ``save_as_continue`` is set to ``True``.
+
.. attribute:: ModelAdmin.save_on_top
Set ``save_on_top`` to add save buttons across the top of your admin change
diff --git a/docs/releases/1.10.txt b/docs/releases/1.10.txt
index c2d34c5992..05f3c20b1a 100644
--- a/docs/releases/1.10.txt
+++ b/docs/releases/1.10.txt
@@ -753,6 +753,13 @@ Miscellaneous
model, you must convert them to attributes or properties as described in
:ref:`the deprecation note <user-is-auth-anon-deprecation>`.
+* When using :attr:`ModelAdmin.save_as=True
+ <django.contrib.admin.ModelAdmin.save_as>`, the "Save as new" button now
+ redirects to the change view for the new object instead of to the model's
+ changelist. If you need the previous behavior, set the new
+ :attr:`ModelAdmin.save_as_continue
+ <django.contrib.admin.ModelAdmin.save_as_continue>` attribute to ``False``.
+
.. _deprecated-features-1.10:
Features deprecated in 1.10