Commit Graph

6876 Commits

Author SHA1 Message Date
Aymeric Augustin e2f9c11736 Fixed #16705 - Made the test client adhere to the WSGI spec -- in particular, removed the assumption that environ['QUERY_STRING'] exists.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16933 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-06 20:39:15 +00:00
Luke Plant b763412aa4 Removed ForeignRelatedObjectsDescriptor.RelatedManager.delete_manager, which has been unused since [14507]
And cleaned up the result, allowing more consistency with the other related
descriptors.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16931 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-06 11:08:11 +00:00
Luke Plant 662eea116f Fixed #16937 - added `QuerySet.prefetch_related` to prefetch many related objects.
Many thanks to akaariai for lots of review and feedback, bug finding,
additional unit tests and performance testing.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16930 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 23:14:52 +00:00
Luke Plant d30fbf8b78 Fixed #16902 - select_related() results in a poor perfomance
Thanks to ivan_virabyan for the great patch!

(For the record, some very small tweaks were made by me).

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16929 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 22:56:09 +00:00
Julien Phalip 03d4a8d1b6 Fixed #16990 -- Fixed a couple of small docstring typos in the `django/test/testcases.py` module and did some minor cleanup while I was in the area.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16928 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 12:50:44 +00:00
Luke Plant 05cf72bace Very small docstring correction.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16927 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 09:54:01 +00:00
Paul McMillan 1ac2bb9b8e Fixed #16987 -- Improved error message for session tests. Thanks jMyles and DiskSpace for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16926 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 05:21:47 +00:00
Aymeric Augustin 2a044732f6 Fixed #16971 - Made the parsing of javascript files by 'makemessages' much faster. Thanks Antti Haapala for the implementation and Ned Batchelder for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16924 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-04 20:11:41 +00:00
Ramiro Morales 0d9b6a5bc4 Fixed #10841 -- Switched response served when DEBUG=True and request.is_ajax() returns True (indicating request has been generated by a JS library) to a plain text version for easier debugging.
Contents of this response are similar to its HTML counterpart modulo frame variables values in the Python traceback section.

Thanks to Riz for the report, to SmileyChris for the patch and to Julien for reviewing.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16921 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-02 02:53:58 +00:00
Luke Plant 10d90cba83 Fixed #16935 - misleading message if AttributeError escapes during SimpleTemplateResponse.render
Thanks to isagalaev for the report.

As discussed on django-devs, this reverts some of the changes in [16568]
i.e.  the addition of `SimpleTemplateResponse.__getattr__`, because this
makes it much harder to debug the common case of an AttributeError somewhere
during the rendering of a SimpleTemplateResponse.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16917 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-30 11:46:23 +00:00
Luke Plant 5009e45dfe Fixed #14270 - related manager classes should be cached
Thanks to Alex Gaynor for the report and initial patch, and mrmachine for
more work on it.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16916 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-30 10:41:25 +00:00
Luke Plant ec5bfed57a Made GenericRelatedObjectManager consistent with other related managers w.r.t. use of core_filters attribute.
Previously it had an unused keyword argument.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16914 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-29 15:30:37 +00:00
Luke Plant 6d6fe61bf6 Cleanups to related manager code, especially in use of closures.
The related manager classes are defined within functions, and the methods
had inconsistent and confusing usage of closures vs. parameters on self to
retrieve needed information. Everything is stored on self now.

Also some methods were not using super() where they should have been.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16913 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-29 15:30:29 +00:00
Luke Plant e3a6ac8f60 Small cleanups of 'related manager' code for consistency
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16912 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-29 15:30:19 +00:00
Julien Phalip 8137027fd7 Fixed #13956 -- Enabled `*args` and `**kwargs` support for `simple_tag`, `inclusion_tag` and `assignment_tag`. Many thanks to Stephen Burrows for the report and initial patch, to Gregor Müllegger for the initial tests, to SamBull for the suggestions, and to Jannis Leidel for the review and PEP8 cleanup.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16908 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-27 12:15:15 +00:00
Luke Plant 29b8e34dfb Removed unused parameter 'join_table' in various bits of RelatedManager code
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16907 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-26 17:20:20 +00:00
Ramiro Morales 735fbcfe8b Fixed #16597 -- Added Sphinx cross-reference metadata to the form wizard docs. Thanks FunkyBob for the report and jkistler for the patch.
Also, additional fixes in that document and in the WizardView docstrings.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16904 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-26 01:37:57 +00:00
Ramiro Morales 3ef1762cb9 Fixed #16924 -- Corrected `date` template filter handling of negative (West of UTC) timezone offsets.
The 'O' format specifier output was incorrect. Thanks mrgriscom and Aymeric Augustin.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16903 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-25 17:08:31 +00:00
Julien Phalip 482388cd61 Fixed #16927 -- Corrected the `{% ifchanged %}` template tag's documentation. Thanks to sebastian for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16902 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-25 05:21:29 +00:00
Ramiro Morales 4c457bca85 Fixed #16789 -- Added names to URLs in convenience contrib.auth urls.py.
Thanks wim AT go2people DOT nl for the report, cmheisel for the patch and
fcurella for reviewing it.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16901 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-24 19:48:27 +00:00
Jannis Leidel ce9e3b4e97 Fixed a regression introduced in r16897. Thanks to Julien for the eagle eyes and Florian Apolloner for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16900 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-24 13:32:57 +00:00
Julien Phalip f2ed107b07 Simplified the admin changelist multi-sort interface specifically by removing the popup window, adding explicit tooltip help texts, improving the hover visual states and allowing all operations (i.e. removing a column from sorting and toggling the sorting with and without changing the sorting priority) to be actionable with just one click. Many thanks to Idan Gazit for the feedback and direction. Refs #16212.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16899 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-24 06:17:53 +00:00
Ramiro Morales b1c3174cfa Removed unused code from admindocs app now that it supports reversing URLs.
As a consequence the undocumented `ADMIN_SITE_ROOT_URL` setting isn't used anymore.

Refs r8718 and r16857.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16898 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-23 23:57:06 +00:00
Jannis Leidel 6cae2a550d Fixed #16878 -- Improved intword filter to support numbers up to decillion and googol. Thanks to crodjer for the initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16897 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-23 16:45:40 +00:00
Carl Meyer 0a9c52e013 Fixed #16917 -- Don't try to use the model name for a ContentType's unicode representation if the model no longer exists. Thanks Ivan Sagalaev for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16895 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-23 04:22:30 +00:00
Gabriel Hurley 39bbd1653a Fixed #7198 (again) -- Corrects a problem with string interpolation from r16876 and adds tests for the new error message.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16888 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 21:09:00 +00:00
Ramiro Morales bb641631e5 Fixed #16912 -- Fixed breadcrumb styling in a couple of admin pages, broken since r16857. Thanks Florian Apolloner for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16887 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 17:04:05 +00:00
Jannis Leidel 66dc22c2d9 Fixed #16909 -- Pass language to get_format_modules when calling it from get_format to make sure the correct module is returned.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16884 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 15:04:27 +00:00
Paul McMillan c59339f450 Fixed #16565 -- Fixed a databrowse error on null foreign key, even though databrowse is deprecated. Thanks aaugustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16883 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 06:37:50 +00:00
Paul McMillan d0979a5faf Fixed #6011 -- Improved help text for flush command. Thanks Julien for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16877 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 05:21:51 +00:00
Paul McMillan f44c4a5d0f Fixed #7198 -- Improved error message when missing models.py. Thanks Silver_Ghost and for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16876 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 05:10:52 +00:00
Paul McMillan 1d96d886e7 Fixed #16026 -- loaddata now identifies which object triggered an error.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16873 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 04:30:20 +00:00
Paul McMillan 0781ed8ec8 Fixed #16837 -- Improved error message for admin login.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16872 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 04:16:21 +00:00
Paul McMillan 5a01324f20 Fixed #16907 -- Deprecate databrowse.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16871 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 04:10:02 +00:00
Carl Meyer f91af72523 Fixed #16353 -- don't try to create Site objects on all databases. Refs #15573, #15346. Thanks Aymeric Augustin for the report and the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16868 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 22:46:48 +00:00
Julien Phalip 8f750bf6e5 Fixed #16897 -- Fixed some docstrings and help texts for the `makemessages` management command. Thanks, Simon Meers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16864 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 17:25:13 +00:00
Jannis Leidel c4cc875643 Fixed #16703 -- Raise an exception if the storage location of the DefaultStorageFinder is empty.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16863 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 15:58:32 +00:00
Jannis Leidel eb5df8e98d Fixed the relative static file resolution of the CachedStaticFilesStorage backend and the post processing of deeply nested static files.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16862 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 15:58:21 +00:00
Carl Meyer 75199e8f6d Fixed #16866 -- Clearer error message if empty list is passed to select_template. Thanks Silver_Ghost for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16861 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 14:20:18 +00:00
Carl Meyer 09a01435de Fixed #16838 -- Corrected broken add-another inline JS in admin with related_name="+". Thanks jamesp for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16860 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 14:00:58 +00:00
Ramiro Morales aaf77c1676 Converted internal link generation in the admin and admin document generator to use named URLs.
Thanks to Florian Apolloner for both the initial patch and his final push to get
this fixed, to Dario Ocles for his great work on the admin templates and
switching the admin_doc application to also use named URLs, to Mikko Hellsing
for his comments and to Jannis and Julien for their review and design guidance.

Fixes #15294.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16857 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-20 18:30:06 +00:00
Julien Phalip 212b048564 Fixed #16659 -- Made the admin's date drilldown links in the changelist have a variable width to play nicer with languages with long month names.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16854 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-19 07:25:59 +00:00
Justin Bronn e5aeba018f Updated geoadmin tests to reflect that OSM js is no longer required as of r16847.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16853 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 22:28:17 +00:00
Paul McMillan d15ef4532e Removed an unused function definition.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16852 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 21:33:14 +00:00
Julien Phalip 436aeb6e15 Fixed #16676 -- Corrected the behavior of the 'add' template filter to return an empty string instead of the given value unchanged in the case of an invalid use. Thanks to dtrebbien for the report and to Aymeric Augustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16851 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 08:33:39 +00:00
Chris Beaven e63fa0ff83 Fixes #8103 -- Select widget should only allow for one selected option
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16848 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 04:09:44 +00:00
Justin Bronn 1ec25c4fb7 OpenLayers has had built-in OSM support since 2.10, no need for extra JS.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16847 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-17 23:01:46 +00:00
Justin Bronn 30745b2e65 Updated the geographic admin to use OpenLayers 2.11.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16846 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-17 20:06:00 +00:00
Justin Bronn 3ac877840a Fixed #15277 -- Cleaned up `ogrinspect` command, added tests and extended support beyond file-based OGR data sources. Thanks, willinoed for bug report and jpaulett for initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16845 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-17 19:54:52 +00:00
Justin Bronn f97a574196 Fixed #16864 -- WKT regex now allows negative SRIDs. Thanks, Marcel Dancak for bug report and initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16843 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-16 21:19:30 +00:00