django1/django/contrib/admin
Jacob Kaplan-Moss f212b24b64 Cleaned up and refactored `ModelAdmin.formfield_for_dbfield`:
* The new method uses an admin configuration option (`formfield_overrides`); this makes custom admin widgets especially easy.
  * Refactored what was left of `formfield_for_dbfield` into a handful of smaller methods so that it's easier to hook in and return custom fields where needed.
  * These `formfield_for_*` methods now pass around `request` so that you can easily modify fields based on request (as in #3987).

Fixes #8306, #3987, #9148.

Thanks to James Bennet for the original patch; Alex Gaynor and Brian Rosner also contributed.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@9760 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-16 15:32:31 +00:00
..
media Fixed #9642 -- Made the admin calendar/clock popups go away when the users clicks outside them. The previous javascript code did not work on IE. Thanks northtea for the report and patch. 2008-11-21 14:52:58 +00:00
templates Fixed #9637: Use 'block.super' in admin 'extrastyle' blocks to preserve changes in base_site.html 2008-12-27 00:01:11 +00:00
templatetags The second part of fixing "related inherited models" display. Handle raw_id values for child models in the admin. Fixed #9461. 2008-12-08 08:16:26 +00:00
views Fixed #9795: Since related-object selection widgets take limit_choices_to into account, the offending code is no longer necessary and can simply be removed. 2008-12-11 07:06:25 +00:00
__init__.py Fixed #8245 -- Added a LOADING flag to autodiscover to prevent an admin.py module with errors from raising a spurious AlreadyRegistered exception in a subsequent call to autodiscover. 2008-12-23 18:25:24 +00:00
filterspecs.py Fixed #3096 -- Make admin list_filters respect limit_choices_to. 2008-10-21 19:03:21 +00:00
helpers.py Fixed #9498 -- Handle a formset correctly when the foreign key is not available (for now). 2008-11-13 19:03:44 +00:00
models.py Merged the newforms-admin branch into trunk. 2008-07-18 23:54:34 +00:00
options.py Cleaned up and refactored `ModelAdmin.formfield_for_dbfield`: 2009-01-16 15:32:31 +00:00
sites.py Fixed #6470: made the admin use a URL resolver. 2009-01-14 20:22:25 +00:00
util.py Fixed #6470: made the admin use a URL resolver. 2009-01-14 20:22:25 +00:00
validation.py Fixed regression introduced in r9550 2008-12-03 15:47:19 +00:00
widgets.py Fixed an issue in ForeignKeyRawIdWidget where the values in limit_choices_to were always treated as lists even when they weren't 2008-11-26 21:21:43 +00:00