Kaydet (Commit) 340eaded authored tarafından Russell Keith-Magee's avatar Russell Keith-Magee

Fixed #15116 -- Strip ordering clause from in_bulk() queries, since ordering…

Fixed #15116 -- Strip ordering clause from in_bulk() queries, since ordering information will be lost. Thanks to lamby for the report and patch.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@15457 bcc190cf-cafb-0310-a4f2-bffc1f526a37
üst 4e7c2ba1
......@@ -419,6 +419,7 @@ class QuerySet(object):
return {}
qs = self._clone()
qs.query.add_filter(('pk__in', id_list))
qs.query.clear_ordering(force_empty=True)
return dict([(obj._get_pk_val(), obj) for obj in qs.iterator()])
def delete(self):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment