summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Kaplan-Moss <jacob@jacobian.org>2009-04-22 22:45:23 +0000
committerJacob Kaplan-Moss <jacob@jacobian.org>2009-04-22 22:45:23 +0000
commitd6829782d0001a08526f6b8465302865842990dc (patch)
treeccc763448999f162e0bda114dbd70fe4957767ec
parent6d1837a8bf31e23209c57155e402ad11debbf511 (diff)
Now that formsets guarentee ordering (see [10623]) we can remove the arbitrary validation of this fact added as part of [10077].
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10628 bcc190cf-cafb-0310-a4f2-bffc1f526a37
-rw-r--r--django/contrib/admin/validation.py4
-rw-r--r--docs/ref/contrib/admin/index.txt5
2 files changed, 1 insertions, 8 deletions
diff --git a/django/contrib/admin/validation.py b/django/contrib/admin/validation.py
index 3392714f5d..3243bf86e1 100644
--- a/django/contrib/admin/validation.py
+++ b/django/contrib/admin/validation.py
@@ -67,10 +67,6 @@ def validate(cls, model):
# list_editable
if hasattr(cls, 'list_editable') and cls.list_editable:
check_isseq(cls, 'list_editable', cls.list_editable)
- if not (opts.ordering or cls.ordering):
- raise ImproperlyConfigured("'%s.list_editable' cannot be used "
- "without a default ordering. Please define ordering on either %s or %s."
- % (cls.__name__, cls.__name__, model.__name__))
for idx, field_name in enumerate(cls.list_editable):
try:
field = opts.get_field_by_name(field_name)[0]
diff --git a/docs/ref/contrib/admin/index.txt b/docs/ref/contrib/admin/index.txt
index f277d08d4d..700303fbf7 100644
--- a/docs/ref/contrib/admin/index.txt
+++ b/docs/ref/contrib/admin/index.txt
@@ -424,16 +424,13 @@ edit and save multiple rows at once.
``list_editable`` interacts with a couple of other options in particular
ways; you should note the following rules:
- * To use ``list_editable`` you must have defined ``ordering`` on either
- your model's or your ``ModelAdmin``'s inner ``Meta``.
-
* Any field in ``list_editable`` must also be in ``list_display``. You
can't edit a field that's not displayed!
* The same field can't be listed in both ``list_editable`` and
``list_display_links`` -- a field can't be both a form and a link.
- You'll get a validation error if any of these rules are broken.
+ You'll get a validation error if either of these rules are broken.
.. attribute:: ModelAdmin.list_filter