Mercurial > hg > savane-forge
changeset 163:93706e459c8d
More notes on Django 1.2
author | Sylvain Beucler <beuc@beuc.net> |
---|---|
date | Fri, 14 May 2010 22:17:03 +0200 |
parents | 0fef7ef3d585 |
children | 1f357ce5d7dc |
files | doc/DJANGO urls.py |
diffstat | 2 files changed, 16 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/doc/DJANGO +++ b/doc/DJANGO @@ -19,3 +19,8 @@ "get_object_or_404(ExtendedUser, pk=request.user.pk)" calls with something that actually creates the ExtendedUser if the user is just a basic user. + +- In Django 1.2, the combination of aggregation and filters is buggy, + and voluntarily released that way without so much of a release note. + Don't rely on it. + http://code.djangoproject.com/ticket/11293
--- a/urls.py +++ b/urls.py @@ -20,8 +20,10 @@ from django.conf.urls.defaults import * from django.conf import settings +urlpatterns = patterns('',) + # Home/presentation pages -urlpatterns = patterns('', +urlpatterns += patterns('', (r'', include('savane.svmain.urls')), ) @@ -44,14 +46,14 @@ import django admin.autodiscover() -if django.VERSION[0] > 1 or (django.VERSION[0] == 1 and django.VERSION[1] >= 1): - urlpatterns += patterns('', - (r'^admin/', include(admin.site.urls)), - ) -else: - urlpatterns += patterns('', - (r'^admin/(.*)', admin.site.root), - ) +urlpatterns += patterns('', + # Uncomment the admin/doc line below and add 'django.contrib.admindocs' + # to INSTALLED_APPS to enable admin documentation: + (r'^admin/doc/', include('django.contrib.admindocs.urls')), + + # Uncomment the next line to enable the admin: + (r'^admin/', include(admin.site.urls)), +) # Static content