Author: sevein
Date: Tue Nov 30 15:29:39 2010
New Revision: 34
Log:
Cosmetic changes. Use static.serve() view to serve media files during
development.
Modified:
trunk/urls.py
Modified: trunk/urls.py
==============================================================================
--- trunk/urls.py Mon Oct 11 05:24:07 2010 (r33)
+++ trunk/urls.py Tue Nov 30 15:29:39 2010 (r34)
@@ -1,34 +1,29 @@
from django.conf.urls.defaults import *
-from qubitupdatecheck.chk4upd.views import *
+from django.conf import settings
-# Uncomment the next two lines to enable the admin:
-# from django.contrib import admin
-# admin.autodiscover()
+from qubitupdatecheck.chk4upd.views import *
urlpatterns = patterns('',
- # Example:
- # (r'^qubitUpdateCheck/', include('qubitUpdateCheck.foo.urls')),
- # 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)),
-
- # Root page
- (r'^$', index),
-
- # Auth
- (r'^login/$', 'django.contrib.auth.views.login', {'template_name':
'login.html'}),
- (r'^logout/$', logout),
-
- # Basic actions
- (r'^check/$', check),
- (r'^delete/(?P<id>\d+)/$', delete),
- (r'^gethostbyaddr/$', gethostbyaddr),
-
- # Report
- (r'^report/$', report),
- (r'^report/page/(?P<page>\d+)/$', report),
+ # Root page
+ (r'^$', index),
+
+ # Auth
+ (r'^login/$', 'django.contrib.auth.views.login', {'template_name':
'login.html'}),
+ (r'^logout/$', logout),
+
+ # Basic actions
+ (r'^check/$', check),
+ (r'^delete/(?P<id>\d+)/$', delete),
+ (r'^gethostbyaddr/$', gethostbyaddr),
+
+ # Report
+ (r'^report/$', report),
+ (r'^report/page/(?P<page>\d+)/$', report),
+
)
+
+if settings.DEBUG:
+ urlpatterns += patterns('',
+ (r'^static/(?P<path>.*)$', 'django.views.static.serve', {'document_root':
''}),
+ )
--
You received this message because you are subscribed to the Google Groups
"Qubit Toolkit Commits" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/qubit-commits?hl=en.