Commit Graph

1053 Commits

Author SHA1 Message Date
Jacob Kaplan-Moss c823e9d7cc Added row highlighting when selecting action checkmarks.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10258 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-31 16:24:12 +00:00
Gary Wilson Jr b4f5655c86 Fixed #10553 -- Corrected several uses of `URLconf` in documentation and comments, according to the Django style guide. Based on patch from rduffield.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10256 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-31 16:07:07 +00:00
Justin Bronn 3a0950739b Fixed #9437 -- Now close database connection within `get_srid_info`. Thanks, mattxbart.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10254 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-31 15:49:25 +00:00
Gary Wilson Jr 7372ea159a Fixed #10389, #10501, #10502, #10540, #10562, #10563, #10564, #10565, #10568, #10569, #10614, #10617, #10619 -- Fixed several typos as well as a couple minor issues in the docs, patches from timo, nih, bthomas, rduffield, UloPe, and sebleier@gmail.com.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10242 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-31 07:01:01 +00:00
Jacob Kaplan-Moss 4378af21b6 Fixed #10537: Fixed the foreign key add-another link in list_editable. Thanks, Alex and jezdez.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10235 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 23:16:34 +00:00
Jacob Kaplan-Moss 4e035a03b6 Fixed #8749: add better breadcrumbs in the change password template. Thanks, SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10234 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 23:00:55 +00:00
Justin Bronn a1e7723c79 Fixed the `add_postgis_srs` routine to support SpatiaLite.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10229 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 22:54:24 +00:00
Jacob Kaplan-Moss 6ce25d3be9 Fixed #10413: RelatedManager.add no longer fails silenty when trying to add an object of the wrong type. Thanks, dgouldin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10226 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 22:41:49 +00:00
Justin Bronn 8eca2df3a4 Fixed #9686 -- SpatiaLite is now a supported spatial database backend. Thanks to Matthew Hancher for initial patch and hard work in implementing this feature.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10222 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 22:15:41 +00:00
Gary Wilson Jr 5ff1703f41 Fixed #9130 -- Fixed typo in comment, thanks scel.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10220 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 22:10:36 +00:00
Gary Wilson Jr 3989a7ae11 Fixed #8140 -- Made `UserManager.create_superuser` return the new `User` object, based on patch from ericholscher.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10217 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 22:00:07 +00:00
Justin Bronn 867e71501c Refactored and cleaned up parts of the spatial database backend. Changes include:
* Laid foundations for SpatiaLite support in `GeoQuerySet`, `GeoWhereNode` and the tests.
* Added the `Collect` aggregate for PostGIS (still needs tests).
* Oracle now goes to 11.
* The backend-specific `SpatialRefSys` and `GeometryColumns` models are now attributes of `SpatialBackend`.
* Renamed `GeometryField` attributes to be public that were private (e.g., `_srid` -> `srid` and `_geom` -> `geom_type`).
* Renamed `create_test_db` to `create_test_spatial_db`.
* Removed the legacy classes `GeoMixin` and `GeoQ`.
* Removed evil `\` from spatial backend fields.
* Moved shapefile data from `tests/layermap` to `tests/data`.

Fixed #9794.  Refs #9686.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@10197 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-30 17:15:49 +00:00
Wilson Miner c0ee4c5cac Some minor tweaks to the admin changelist styles for the new action menus. Cut out extranous margins around checkboxes on changelists and styled the action row to stack better with the date hierarchy browser.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10181 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-29 23:05:51 +00:00
Brian Rosner 69977d2045 Fixed #10622 -- Resolved an issue with model inheritence and list_editable. Thanks oyvind and Alex Gaynor.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10178 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-29 18:52:38 +00:00
Justin Bronn f0b7cc4a23 Cleanup, bug fixes, and new tests for the GEOS I/O objects and `GEOSBase` object.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10177 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-28 16:36:48 +00:00
Justin Bronn 0b9a855bed Fixed #10620 -- removed carriage returns in a GEOS tests module; fixed other errata such as unnecessary `pymutable_geometries` module and not having `GEOSGeometry` call `__init__`.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10174 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-26 02:07:11 +00:00
Malcolm Tredinnick 7f63d0009f Fixed a ungettext() call to prevent spurious string extraction by xgettext.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10168 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-25 01:31:57 +00:00
Malcolm Tredinnick 2dfdc2b01b Fixed #10600 -- Allow for format marker reordering in a translatable string.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10141 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-24 08:22:23 +00:00
Malcolm Tredinnick 37f25d4c0c Fixed #9994 -- Fixed admin filtering when to_field is used on relations.
Thanks to jzylks for diagnosing this one.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10139 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-24 07:05:57 +00:00
Justin Bronn 91ebe9acae Fixed error when trying to import the GEOS tests from their new location.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10137 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-24 04:26:56 +00:00
Brian Rosner c5aa6fa710 Fixed #10597 -- select all checkbox on admin changelist now works under IE 6 and 7. Thanks kyle.fox.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10135 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-24 03:11:38 +00:00
Justin Bronn 66e1670efa Refactored the GEOS interface. Improvements include:
* Geometries now allow list-like manipulation, e.g., can add, insert, delete vertexes (or other geometries in collections) like Python lists.  Thanks, Aryeh Leib Taurog.
* Added support for GEOS prepared geometries via `prepared` property.  Prepared geometries significantly speed up certain operations.
* Added support for GEOS cascaded union as `MultiPolygon.cascaded_union` property.
* Added support for GEOS line merge as `merged` property on `LineString`, and `MultiLineString` geometries.  Thanks, Paul Smith.
* No longer use the deprecated C API for serialization to/from WKB and WKT.  Now use the GEOS I/O classes, which are now exposed as `WKTReader`, `WKTWriter`, `WKBReader`, and `WKBWriter` (which supports 3D and SRID inclusion)
* Moved each type of geometry to their own module, eliminating the cluttered `geometries.py`.
* Internally, all C API methods are explicitly called from a module rather than a star import.

Fixed #9557, #9877, #10222


git-svn-id: http://code.djangoproject.com/svn/django/trunk@10131 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-24 00:12:21 +00:00
Jacob Kaplan-Moss f0560dfdb2 Fixed #9282: added a generic comment moderation toolkit. See the documentation for details.
This began life as (part of) James Bennett's comment-utils app, and was adapted to be part of Django by Thejaswi Puthraya and Jannis Leidel. Thanks, all!

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10122 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-23 21:07:02 +00:00
Jacob Kaplan-Moss 44f3080226 Fixed #10505: added support for bulk admin actions, including a globally-available "delete selected" action. See the documentation for details.
This work started life as Brian Beck's "django-batchadmin." It was rewritten for inclusion in Django by Alex Gaynor, Jannis Leidel (jezdez), and Martin Mahner (bartTC). Thanks, guys!

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10121 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-23 20:22:56 +00:00
Karen Tracey 14b160957e Fixed #8962 -- Consistently support format and input_format in the various (individual, combined, split) date and time form fields and widgets.
Many thanks to Tai Lee for doing all the work here.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@10115 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-22 16:13:06 +00:00
Jacob Kaplan-Moss 231a7e0419 Fixed #9958: split the `CommentForm` into a set of smaller forms. This for better encapsulation, but also so that it's easier for subclasses to get at the pieces they might need. Thanks to Thejaswi Puthraya.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10110 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-21 13:45:31 +00:00
Jacob Kaplan-Moss e923b545a4 Fixed #9303 (again) by removing some code missing in [9891].
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10109 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-21 13:45:15 +00:00
Justin Bronn 44b0f68f44 GeoDjango test suite now takes advantage of `importlib` added in r10088.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10103 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-20 02:50:48 +00:00
Justin Bronn 9eb061b2c0 Fixed #10480 -- made `icons` a property to add more flexibility.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10102 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-20 02:10:47 +00:00
Jacob Kaplan-Moss c485e236bd Fixed #8193: all dynamic imports in Django are now done correctly. I know this because Brett Cannon borrowed the time machine and brought Python 2.7's '`importlib` back for inclusion in Django. Thanks for the patch-from-the-future, Brett!
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10088 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-18 16:55:59 +00:00
Malcolm Tredinnick 4a67fee785 Fixed #10533 -- Worked around an apparent limitation of xgettext.
Looks like we have to use the same format specifiers in both singular and
plural forms of a message or the PO file cannot be compiled to MO format. This
commit changes one place in admin that was using different specifiers.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10081 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-18 09:19:24 +00:00
Jacob Kaplan-Moss 4a88785e38 Fixed #10530, #10527: added a couple more validation errors around `list_editable`. Thanks, Florian Apolloner.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10080 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-18 03:03:24 +00:00
Jacob Kaplan-Moss 7bc0878922 Fixed #8939: added a `list_editable` option to `ModelAdmin`; fields declared `list_editable` may be edited, in bulk, on the changelist page. Thanks, Alex Gaynor.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10077 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-17 20:51:47 +00:00
Jacob Kaplan-Moss a7d1c73ad9 `ModelAdmin` validation now runs when using the `site.register(Model, **kwargs)` form.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10074 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-17 20:40:01 +00:00
Gary Wilson Jr b994387d8d Fixed #689 -- Added a middleware and authentication backend to contrib.auth for supporting external authentication solutions. Thanks to all who contributed to this patch, including Ian Holsman, garthk, Koen Biermans, Marc Fargas, ekarulf, and Ramiro Morales.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10063 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-15 05:54:28 +00:00
Malcolm Tredinnick 0543f33bbc Fixed the django.contrib.gis test database creation as well.
Refs r10026 and r10027.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10028 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-11 05:48:26 +00:00
Justin Bronn 6aa5aacc86 Fixed #9204 -- Added `GIcon` overlay, allowing customization for icons of `GMarker` objects. Thanks to qingfeng for initial ticket/patch, and to prairiedogg for final implementation.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10021 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-10 18:03:35 +00:00
Russell Keith-Magee 3c8568a7dc Fixed #10271, #10281 -- Fixed the handling multiple inline models that share a common base class and have the link to the inline parent on the base class. Includes modifications that allow the equivalent handling for GenericFields. Thanks to Idan Gazit, Antti Kaihola (akaihola), and Alex Gaynor for their work on this patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10017 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-10 11:19:26 +00:00
Justin Bronn d45e24a1f8 Fixed #9955 -- Added `GoogleMapSet`, which enables multiple `GoogleMap` objects to placed on the same page; moved all templates to `google` parent dir, and added 'google-map.html' for an included example. Thanks to mandric for the ticket and aromano for initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10011 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-09 19:22:24 +00:00
Malcolm Tredinnick 35f934f5a7 Pass values through get_db_prep_save() in a QuerySet.update() call.
This removes a long-standing FIXME in the update() handling and allows for
greater flexibility in the values passed in. In particular, it brings updates
into line with saves for django.contrib.gis fields, so fixed #10411.

Thanks to Justin Bronn and Russell Keith-Magee for help with this patch.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10003 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-09 00:03:03 +00:00
Justin Bronn cee31735f7 Fixed #10072 -- `GMarker` overlays now have `draggable` option. Thanks to prairiedogg for ticket and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10002 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-08 18:34:24 +00:00
Justin Bronn f1ada99997 Maintenance refactor of the GDAL (OGR) ctypes interface. Changes include:
* All C API method explictly called from their prototype module, no longer imported via *.
* Applied DRY to C pointer management, classes that do so subclass from `GDALBase`.
* `OGRGeometry`: Added `from_bbox` class method (patch from Christopher Schmidt) and `kml` property.
* `SpatialReference`: Now initialize with `SetFromUserInput` (initialization is now more simple and flexible); removed duplicate methods.
* `Envelope`: Added `expand_to_include` method and now allow same coordinates for lower left and upper right points.  Thanks to Paul Smith for tickets and patches.
* `OGRGeomType`: Now treat OGC 'Geometry' type as 'Unknown'.

Fixed #9855, #10368, #10380.  Refs #9806.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@9985 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-07 23:02:48 +00:00
Justin Bronn 68f81c873d Fixed #10397 -- made GIS test runner compatible with changes in r9756.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9978 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-06 02:01:20 +00:00
Justin Bronn 9b8c712ca7 Fixed #10159 -- `F()` expressions now work on geographic fields. The tests are in `relatedapp`, which has been retrofitted to work with Oracle (minus the prior offending tests). I'm back.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9963 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-03 22:10:15 +00:00
Malcolm Tredinnick fdca9e55e8 Fixed #10395 -- Fixed more fallout from r9945.
(Simultaneously, stop django.contrib.gis using some internal attribute when
there's a perfectly good public property available to do the same thing.)

git-svn-id: http://code.djangoproject.com/svn/django/trunk@9960 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-03 02:45:15 +00:00
Malcolm Tredinnick 79f6cce291 Fixed #10385 -- Fixed a typographical error in the Czech regions list.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9940 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-02 00:26:55 +00:00
Malcolm Tredinnick d77236960a Fixed #9548 -- Correctly detect existence of empty sessions with cache backend.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9934 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-03-01 07:32:41 +00:00
Malcolm Tredinnick 0dd4ec654f Invalidate the appropriate SITE_CACHE entry when saving a Site model.
This avoids the problem of, for example, saving a change to the Site model in
the admin interface and then seeing the wrong instanec returned in the next
call to get_current_site().

It's still possible to end up with an inconsistent cache if update() is used to
change the Site model, but that's pretty unavoidable. It's also a slightly odd
way to update a Site model, so if you really need to do that, you can manage to
call SiteManager.clear() at the same time.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@9908 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-27 04:57:33 +00:00
Luke Plant 1306079a02 Fixed #10017 - PasswordResetForm.clean_email was not returning the value.
Thanks Zak Johnson, Leo


git-svn-id: http://code.djangoproject.com/svn/django/trunk@9906 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-26 17:11:28 +00:00
Jacob Kaplan-Moss 1aac357d34 Fixed #9303: comment templatetags no longer assume the built-in comment model.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9891 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-23 22:46:32 +00:00
Jacob Kaplan-Moss 63d85a684a Fixed #8630: finished the custom comment app API that was left out of 1.0. This means it's now possible to override any of the models, forms, or views used by the comment app; see the new custom comment app docs for details and an example. Thanks to Thejaswi Puthraya for the original patch, and to carljm for docs and tests.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9890 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-23 22:16:26 +00:00
Jacob Kaplan-Moss 7d4a954836 Refactored CommentForm.get_comment_object into a handful of separete methods to make it easier for subclasses to provide custom models and data. Refs #8630.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9889 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-23 22:16:00 +00:00
Brian Rosner 4bd24474c0 Fixed #10274 -- Fixed an embarrassing mistake in BaseGenericInlineFormSet.get_queryset. Thanks Zak Johnson for the report and akaihola for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9886 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-23 04:30:38 +00:00
Russell Keith-Magee 8569157664 Fixed #9276 -- Corrected the way the CSS class is rolled out in a stacked edit-inline template. Thanks to creecode@gmail.com for the report and fix.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9877 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-22 08:05:40 +00:00
Russell Keith-Magee b2a4377651 Fixed #9066 -- Added Czech localflavor. Thanks to Elvard for the contribution.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9876 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-22 07:51:57 +00:00
Russell Keith-Magee 39dd44570c Fixed #10025 -- Corrected two minor typos in source documentation. Thanks to Tarken for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9861 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-22 06:08:37 +00:00
Russell Keith-Magee 8242735405 Fixed #10307 -- Removed references to FM/Federated States of Micronesia from the US localflavor STATES_NORMALIZED setting. Thanks to mnd for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9855 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-21 10:10:13 +00:00
Luke Plant 0326574d0e Fixed tabs in source, stupid emacs.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9817 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-07 19:32:37 +00:00
Luke Plant 95ed07e888 Fixed some function name errors in code doc.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9816 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-07 18:06:32 +00:00
Luke Plant 9a2e338107 Made CSRF middleware skip post-processing for 'csrf_exempt' decorated views.
This commit also decomposes the decorator into two decorators which can be
used separately, adds some tests, updates docs and fixes some code comments.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@9815 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-07 17:47:02 +00:00
Justin Bronn 2b8e768b22 Fixed #9858 -- Added ability to use PostGIS template with GIS test runner via `POSTGIS_TEMPLATE` setting. Thanks to Aryeh Leib Taurog for feature suggestion and initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9803 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-01 18:22:57 +00:00
Justin Bronn d982edff4b Now use `subprocess.Popen` instead of the deprecated os.popen3 to issue PostGIS test database creation commands.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9801 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-02-01 17:49:33 +00:00
Justin Bronn 547649f962 Fixed geographic admin to be compatible with `ModelAdmin.formfield_for_dbfield` changes in r9760.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9763 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-16 20:05:39 +00:00
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
Ian Kelly acfe5cc880 Fixed #6767: changed the way the Oracle backend fetches numbers to prevent decimals being returned as floats.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9750 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-15 20:39:09 +00:00
Justin Bronn f60d0f597a Forgot to actually enable the extent aggregate for Oracle.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9749 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-15 19:50:29 +00:00
Justin Bronn f671a5c961 Fixed incomplete merge of geographic aggregates; added support for `Extent` aggregate to Oracle spatial backend. Refs #3566.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9748 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-15 19:35:04 +00:00
Russell Keith-Magee cc4e4d9aee Fixed #3566 -- Added support for aggregation to the ORM. See the documentation for details on usage.
Many thanks to:
 * Nicolas Lara, who worked on this feature during the 2008 Google Summer of Code.
 * Alex Gaynor for his help debugging and fixing a number of issues.
 * Justin Bronn for his help integrating with contrib.gis.
 * Karen Tracey for her help with cross-platform testing.
 * Ian Kelly for his help testing and fixing Oracle support.
 * Malcolm Tredinnick for his invaluable review notes.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@9742 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-15 11:06:34 +00:00
Jacob Kaplan-Moss 1f84630c87 Fixed #6470: made the admin use a URL resolver.
This *is* backwards compatible, but `admin.site.root()` has been deprecated. The new style is `('^admin/', include(admin.site.urls))`; users will need to update their code to take advantage of the new customizable admin URLs.

Thanks to Alex Gaynor.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@9739 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-14 20:22:25 +00:00
Justin Bronn 6c4e5f0f0e Fixed #9278, #9694 -- Geographic overlays now display in admin with right to left langauges; simplified transformation process in `OpenLayersWidget` to fix Ubuntu 8.10/Apache 2.2.9 crash; updated OpenLayers version to 2.7.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9733 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-13 02:08:26 +00:00
Jacob Kaplan-Moss 4035ea3538 A few small fixes to django.contrib.comments (Comment.get_as_text for non-authenticated users; references to Comment.permalink; unused imports). Fixes #9143, #9429, and 9439. Thanks, Thejaswi Puthraya.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9730 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-12 17:27:41 +00:00
Jacob Kaplan-Moss 299e1e814f Fixed #6791: added a write-through cache session backend: session data is written through the cache to the database, but read from the cache for speed. Thanks to jhenry, mcroydon, and jdunck.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9727 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-10 22:18:14 +00:00
Justin Bronn 300752bd6c Return None for null date/time fields in OGR-supported data sources. Thanks to Ariel Mauricio Nunez Gomez for bug report and initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9711 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-07 20:21:19 +00:00
Justin Bronn 391736e737 Updated `GeoWhere` to be compatible with changes in r9700.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9702 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-05 22:16:12 +00:00
Justin Bronn 3cd1e80ae4 Fixed `check_geom` and `check_srs` to accept larger sized pointer addresses as returned by some platforms (including OpenBSD 4.4 and Fedora 8).
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9693 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-01-03 01:37:51 +00:00
Luke Plant a754165a91 Fixed #9637: Use 'block.super' in admin 'extrastyle' blocks to preserve changes in base_site.html
The current admin templates do not need this.  However, a common way to customize admin
appearance is to provide your own 'base_site.html' template, and add stylesheets using
the extrastyle block.  Without this patch, these customizations are lost.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@9690 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-27 00:01:11 +00:00
Justin Bronn 50cd258a24 Fixed #9664 -- `LayerMapping` now works with MySQL spatial backends.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9688 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-26 20:04:11 +00:00
Justin Bronn d39540af92 Fixed #9892 -- support additional binary packages for GEOS & GDAL libs on OSX & Ubuntu platforms.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9686 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-26 16:02:45 +00:00
Adrian Holovaty be2697209b Improved the auth admin site to raise Http404 with a helpful error message if DEBUG is True, explaining why permission isn't denied. Refs #9866, and see also [9682]
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9683 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-25 06:17:42 +00:00
Adrian Holovaty 62362c6175 Added comment to UserAdmin.add_view() explaining why we disallow users without change permissions from adding other users. Refs #9866
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9682 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-25 06:04:11 +00:00
Gary Wilson Jr 9af56803f5 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.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9680 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-23 18:25:24 +00:00
Karen Tracey 986e162c5d Follow-up to r9656 -- beef up the added test to exercise all (one can hope) paths through the troublesome get_deleted_objects function and fix the resulting errors.
Refs #9859.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@9657 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-16 17:42:18 +00:00
Karen Tracey 10894da8a8 Fixed #9859 -- Added another missing force_unicode needed in admin when running on Python 2.3. Many thanks for report & patch to nfg.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9656 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-16 15:04:47 +00:00
James Bennett bb6d5dc69b 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.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9641 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-11 07:06:25 +00:00
Justin Bronn bde736cc5a Fixed a Python 2.4 incompatibility in `compress_kml`.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9607 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-08 14:50:06 +00:00
Justin Bronn 6590c0bcf5 Fixed #9747 -- now explicitly set response type on C functions that return WKB and WKT.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9605 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-08 14:29:06 +00:00
Malcolm Tredinnick 662e12b45c The second part of fixing "related inherited models" display. Handle raw_id values for child models in the admin. Fixed #9461.
I couldn't think of a way to test this automatically and robustly, however,
manual testing with the ticket example shows failure before and success
afterwards and the fix make sense logically.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@9602 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-08 08:16:26 +00:00
Gary Wilson Jr fa7aa7255c Fixed #9732 -- Added missing close paragraph tag to password reset confirmation template, thanks casseen.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9599 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-08 05:41:28 +00:00
Justin Bronn 4058429708 Fixed #9572 -- use `opts` argument. Thanks SeanL for bug report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9572 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-06 01:52:14 +00:00
Justin Bronn 8370e7ca87 Fixed #9742 -- remove extraneous 'kml' from KML mimetype. Thanks, robotika for the bug report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9570 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-06 00:38:48 +00:00
Luke Plant d192236a3d Fixed regression introduced in r9550
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9563 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-03 15:47:19 +00:00
Luke Plant a44d0aace3 Refs #8248 - GenericRelations descriptors now return self when accessed via class
These were missed in r9550 


git-svn-id: http://code.djangoproject.com/svn/django/trunk@9562 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-03 15:45:19 +00:00
Luke Plant 9c33d74f1d Added some explanatory comments in CsrfMiddleware
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9561 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-03 13:23:23 +00:00
Luke Plant 9eedc7bd0b New CsrfMiddleware features: automatic exceptions for known AJAX and decorator for manual exceptions
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9554 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-03 00:34:18 +00:00
Luke Plant c0f9e85fbe Split CsrfMiddleware into two to make it more reusable.
Also converted it to be a view middleware instead of request,
as this allows more options.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@9553 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-03 00:31:31 +00:00
Luke Plant 01ec6d0085 More tests for the other half of CsrfMiddleware
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9552 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-02 23:00:06 +00:00
Luke Plant f7242bb778 Added tests for CsrfMiddleware.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9551 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-12-02 22:40:00 +00:00
James Bennett 8559fc6b35 Fixed an issue in ForeignKeyRawIdWidget where the values in limit_choices_to were always treated as lists even when they weren't
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9533 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-11-26 21:21:43 +00:00
Karen Tracey 380e31ddb7 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.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9514 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-11-21 14:52:58 +00:00
James Bennett 3ba235a348 OneToOne filtering should only apply in a popup selection from the related model.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9507 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-11-20 19:01:40 +00:00