Commit Graph

1322 Commits

Author SHA1 Message Date
Russell Keith-Magee 1db672f347 Fixed #12999 -- Modified the contenttypes syncdb handler to use db router logic. Thanks to lsbardel for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12750 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-10 12:34:49 +00:00
James Bennett a0c77ada99 Ensure that NullBooleanField displays the appropriate icon for null values in admin changelists. Refs #13071.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12746 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-10 08:37:17 +00:00
Karen Tracey bb72aca5d4 Fixed #12689: Fixed admin validation to report an error on invalid exclude specification. Thanks for report to bparker and for patch with tests to ramiro.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12734 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-09 00:38:53 +00:00
Karen Tracey 021ba30ad1 Fixed #12481: Updated admin validation code to not reject non-editable fields in readonly_fields, since these are handled fine by the display code itself. Thanks lashni and Alex.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12730 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-08 20:36:37 +00:00
Karen Tracey f2bc4dd0a9 Fixed #12024: Changed admin code to avoid raising an exception when a field listed
in raw_id_fields has limit_choices_to specified as a Q object. 

Tweaked a test to trigger the condition and verify the fix. 

Finally, documented that limit_choices_to specified as a Q object has no effect 
on the choices available for fields listed in raw_id_fields, and removed another 
incorrect note that claimed limit_choices_to had no effect on inlines in the admin.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@12728 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-08 18:32:24 +00:00
Karen Tracey 80545c3685 Fixed #12151: Ensured the comments code does not cause a server error when a request comes in for a comment specifying an invalid primary key value. Thanks thejaswi_puthraya.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12681 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-05 20:17:52 +00:00
Karen Tracey 2890c2295b Fixed #11465: Ensure nonexistent pks enterd in an admin raw id field do not
cause a server error. Thanks for report and initial patch sacre@wp.pl.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@12648 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-02 02:28:49 +00:00
Jacob Kaplan-Moss 17c466a57b Fixed a silly bug in [12644].
Kids, please don't drink and code; the commit you save might be your own.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12646 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 23:59:22 +00:00
Jacob Kaplan-Moss 4c18facdf7 Fixed #1104: set `FormWizard.extra_context` in `__init__` to avoid context leakage.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12644 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 23:26:08 +00:00
Jacob Kaplan-Moss 973bf6f485 Fixed #5605: only lowercase the domain portion of an email address in `UserManager.create_user`.
Thanks, Leo.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12641 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 20:30:44 +00:00
Jacob Kaplan-Moss 8b2662c5de Fixed #10878, an error in the `Moderator` docstring.
Thanks, Travis Cline.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12639 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 20:18:52 +00:00
Jacob Kaplan-Moss 6e748b5db4 Fixed #11457: tightened the security check for "next" redirects after logins.
The new behavior still disallows redirects to off-site URLs, but now allows
redirects of the form `/some/other/view?foo=http://...`.

Thanks to brutasse.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12635 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 19:58:53 +00:00
Jacob Kaplan-Moss c8015052d9 Fixed #5786: relaxed the validation for usernames to allow more common characters '@', etc.
This is really just a stop-gap until we come up with a improved way of handling
disparate auth data, but it should help us stretch a bit more milage out of the
current system.

Thanks to alextreme, lbruno, and clayg.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12634 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 19:49:05 +00:00
Karen Tracey d2dffd78e6 Fixed #11791: Put hidden input elements in the change list inside td elements so they're valid HTML. Thanks panni and mlavin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12631 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 18:43:27 +00:00
Jannis Leidel e889b69dd2 Fixed #12966 - Force unicode of verbose labels in admin change messages.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12627 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 14:34:24 +00:00
Jannis Leidel 2dafe4ac3a Fixed #12903 - Added plural forms to a few strings in the admin actions template.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12626 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-03-01 14:34:07 +00:00
Luke Plant d7abb33e70 Fixed #12933 - AdminSite.admin_view disables @csrf_view_exempt
Thanks to philomat for report and patch.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@12619 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-27 21:08:30 +00:00
Karen Tracey 9fab1467c7 Removed more stray tabs in Python files.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12616 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-27 16:30:27 +00:00
Russell Keith-Magee 41c30f2fb8 Fixed #12981 -- Removed some stray tabs. Thanks to loewis for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12614 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-27 05:38:17 +00:00
Russell Keith-Magee e12b3199d0 Fixed #6191, #11296 -- Modified the admin deletion confirmation page to use the same object collection scheme as the actual deletion. This ensures that all objects that may be deleted are actually deleted, and that cyclic display problems are avoided. Thanks to carljm for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12598 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-26 13:17:43 +00:00
Justin Bronn dc1ad69f30 Fixed #11353 -- `GeometryProxy` descriptor no longer chokes when accessed from a class rather than an instance, thanks yml and Tobu; removed unnecessary imports from `types` and cleaned up whitespace.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12584 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-24 21:20:02 +00:00
Joseph Kocherhans 3f443363f9 Fixed #11681. Fixed display of non_field_errors and non_form_errors in the admin. Thanks, nessita.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12541 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-23 18:56:00 +00:00
Joseph Kocherhans f2d5582c53 Fixed #12561. InlineAdmin now respects can_delete=False. Thanks, nessita.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12533 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-23 17:14:50 +00:00
Joseph Kocherhans 7aeb37d610 Fixed #12707. Admin action messages are no longer displayed when submitting list_editable content. Thanks, copelco.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12525 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-23 14:48:15 +00:00
Russell Keith-Magee 6b2f125b80 Fixed #12729 -- Replaced a hard-coded SQL statement with an ORM query so that the contrib.auth ModelBackend will work on a routed multi-db setup. Thanks to dhageman for the report.
Historical note: The SQL that was removed predates Django being open sourced.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12509 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-23 12:02:41 +00:00
Justin Bronn 1d5165e3be Fixed #12776 -- `User.get_profile` now raises `SiteProfileNotAvailable` instead of `AttributeError` in certain circumstances. Thanks, Bruno Renié.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12506 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-23 05:52:37 +00:00
Joseph Kocherhans a3e2ddde65 Fixed #12570. Removed unused fields from GenericForeignKey. Thanks, specialunderwear.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12492 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-22 15:48:19 +00:00
Russell Keith-Magee eb67e449dd Fixed #12864 -- Corrected handling of new user creation when a multi-database router is in place. Thanks to haris@dubizzle.com for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12488 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-22 13:09:02 +00:00
Justin Bronn a9b2ac25d1 Fixed #9147 -- Added `FormPreview.process_preview` customization hook. Thanks, bthomas and thalin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12486 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-22 05:00:36 +00:00
Jannis Leidel 67d4289c2e Fixed #12066 - Moved auth context processor from core to the auth app. Thanks, Rob Hudson.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12466 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-21 23:40:47 +00:00
Justin Bronn eaa17e13e8 Fixed #12705 -- Date/time and select filter widgets now work again with newly added inline forms in the admin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12454 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-17 18:54:02 +00:00
Russell Keith-Magee b794441951 Fixed #10976 -- Isolated contrib.auth tests so they will always pass, regardless of any local templates. Thanks to aarond10 for the report, and SmileyChris for turning that into a patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12420 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-13 12:02:11 +00:00
Luke Plant 4bff194633 Fixed #12804 - regression with decorating admin views.
This is a BACKWARDS INCOMPATIBLE change, because it removes the flawed
'auto_adapt_to_methods' decorator, and replaces it with 'method_decorator'
which must be applied manually when necessary, as described in the 1.2
release notes.

For users of 1.1 and 1.0, this affects the decorators:

 * login_required
 * permission_required
 * user_passes_test

For those following trunk, this also affects:

 * csrf_protect
 * anything created with decorator_from_middleware 

If a decorator does not depend on the signature of the function it is
supposed to decorate (for example if it only does post-processing of the
result), it will not be affected.
 



git-svn-id: http://code.djangoproject.com/svn/django/trunk@12399 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-09 15:02:39 +00:00
Jannis Leidel edb6d753a8 Fixed #12716 - Typo in the admin change list template. Thanks, kbrownlees.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12398 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-07 15:55:40 +00:00
Jannis Leidel fdb9f83253 Fixed #12748 - Use charAt instead of array-like access to format string to please IE. Thanks, yedpodtrzitko.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12397 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-07 14:42:16 +00:00
Jannis Leidel f5ee28931d Fixed #12793 - Only use the admin actions JavaScript if not explicitly deactivated with 'actions = None' in the ModelAdmin. Thanks, Florian Apolloner.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12396 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-07 14:41:43 +00:00
Luke Plant def34da85c Fixed #12358 - csrf_token template tag does not work with flatpages.
Thanks to phretor for the report.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@12381 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-04 21:47:19 +00:00
Jannis Leidel 5dad2350f7 Use a closure for embedding the admin actions JavaScript and updated the minified versions a little bit.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12372 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:16:44 +00:00
Jannis Leidel 816fced5d7 Being a good citizen, adding the jQuery license and a command line script to easily minify the jQuery based scripts.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12371 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:16:01 +00:00
Jannis Leidel f839736c60 Fixed #12695 - Force Firefox to not autocomplete input fields that are critical to the dynamic admin inlines.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12370 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:15:27 +00:00
Jannis Leidel 9555f2be9d Fixed #12692 - Properly handle the extra clause of admin inline formsets. Also fixes #12703, second error.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12369 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:14:56 +00:00
Jannis Leidel f70a0882a3 Fixed #12700 - Take read-only fields into account when rendering the empty form for dynamic inlines.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12368 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:13:47 +00:00
Jannis Leidel be90eadfb9 Fixed #12628 - Don't ignore read-only fields in GenericInlineModelAdmin during save. Thanks, Alex Gaynor.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12367 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:13:21 +00:00
Jannis Leidel 267346678d Fixed #12654 - Correctly display ForeignKey fields in read-only scenarios. Thanks, minmax.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12366 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:12:56 +00:00
Jannis Leidel 6c36e1034a Fixed #12726 - Prevent listing media twice in admin's change list. Thanks, jedie.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12365 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-02-01 14:12:24 +00:00
Justin Bronn 0741fb6507 Fixed geographic feed test failure due to `Rss201rev2Feed` additions in r12338.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12357 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-01-29 18:07:49 +00:00
Justin Bronn 901b60e7e1 Now look for `DatabaseError` during PostGIS backend initialization, as it is now raised instead of a `ProgrammingError` after changes in r12352.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12354 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-01-29 17:58:55 +00:00
Russell Keith-Magee 47acb1d659 Fixed #6273 -- Added a 'changepassword' management command. Thanks to Ludvig Ericson and Justin Lilly for their work on this patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12351 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-01-29 08:10:29 +00:00
Justin Bronn 72c39410c8 Renamed `reverse` to `reverse_geom` because of clash with existing `QuerySet` method; added `GeoQuerySet.geohash` support for producing GeoHash reprsentations.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12350 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-01-29 02:46:07 +00:00
Justin Bronn 5b21033847 Added `reverse` and `force_rhr` methods to `GeoQuerySet`. Refs #12416.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12349 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-01-29 02:20:58 +00:00