updated requirements to Django 1.4

This commit is contained in:
Sanj 2012-08-11 14:52:04 +05:30
parent cb518292c0
commit 6c5da14dc4
4 changed files with 11 additions and 6 deletions

View File

@ -2,7 +2,7 @@ from django.contrib.gis import admin
from django import forms from django import forms
from mumbai.models import * from mumbai.models import *
from django.contrib.contenttypes import generic from django.contrib.contenttypes import generic
from django.contrib.admin.filterspecs import FilterSpec, RelatedFilterSpec #from django.contrib.admin.filterspecs import FilterSpec, RelatedFilterSpec
''' '''
class CustomFilterSpec(RelatedFilterSpec): class CustomFilterSpec(RelatedFilterSpec):

View File

@ -54,17 +54,20 @@ USE_L10N = True
# Absolute path to the directory that holds media. # Absolute path to the directory that holds media.
# Example: "/home/media/media.lawrence.com/" # Example: "/home/media/media.lawrence.com/"
MEDIA_ROOT = join(PROJECT_ROOT, 'static') MEDIA_ROOT = join(PROJECT_ROOT, 'media')
# URL that handles the media served from MEDIA_ROOT. Make sure to use a # URL that handles the media served from MEDIA_ROOT. Make sure to use a
# trailing slash if there is a path component (optional in other cases). # trailing slash if there is a path component (optional in other cases).
# Examples: "http://media.lawrence.com", "http://example.com/media/" # Examples: "http://media.lawrence.com", "http://example.com/media/"
MEDIA_URL = '' MEDIA_URL = '/media/'
STATIC_URL = '/static/'
STATIC_ROOT = join(PROJECT_ROOT, 'static')
# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a # URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
# trailing slash. # trailing slash.
# Examples: "http://foo.com/media/", "/media/". # Examples: "http://foo.com/media/", "/media/".
ADMIN_MEDIA_PREFIX = '/admin/media/' #ADMIN_MEDIA_PREFIX = '/admin/media/'
# Make this unique, and don't share it with anybody. # Make this unique, and don't share it with anybody.
try: try:
@ -116,6 +119,7 @@ INSTALLED_APPS = (
'django.contrib.sessions', 'django.contrib.sessions',
'django.contrib.sites', 'django.contrib.sites',
'django.contrib.messages', 'django.contrib.messages',
'django.contrib.staticfiles',
# Uncomment the next line to enable the admin: # Uncomment the next line to enable the admin:
'django.contrib.admin', 'django.contrib.admin',
# Uncomment the next line to enable admin documentation: # Uncomment the next line to enable admin documentation:

View File

@ -14,7 +14,7 @@ urlpatterns = patterns('',
# (r'^chaloBEST/', include('chaloBEST.foo.urls')), # (r'^chaloBEST/', include('chaloBEST.foo.urls')),
url(r'^$','chaloBEST.views.index', name='index'), url(r'^$','chaloBEST.views.index', name='index'),
url(r'^stats/$','mumbai.views.stats', name='stats'), url(r'^stats/$','mumbai.views.stats', name='stats'),
url(r'^static/(?P<path>.*)$','django.views.static.serve', {'document_root':'./static'}), # url(r'^static/(?P<path>.*)$','django.views.static.serve', {'document_root':'./static'}),
(r'^routes/$', 'mumbai.views.routes'), (r'^routes/$', 'mumbai.views.routes'),
(r'^route/(?P<alias>[a-zA-Z0-9\s\-]*?)/$', 'mumbai.views.route'), (r'^route/(?P<alias>[a-zA-Z0-9\s\-]*?)/$', 'mumbai.views.route'),
(r'^route/(?P<alias>[a-zA-Z0-9\s\-]*?)/georss/$', RouteFeed()), (r'^route/(?P<alias>[a-zA-Z0-9\s\-]*?)/georss/$', RouteFeed()),
@ -43,6 +43,7 @@ if settings.LOCAL_DEVELOPMENT:
urlpatterns += patterns('', urlpatterns += patterns('',
# #
(r'^static/(?P<path>.*)$', 'django.views.static.serve', {'document_root': join(settings.PROJECT_ROOT, "static")}), (r'^static/(?P<path>.*)$', 'django.views.static.serve', {'document_root': join(settings.PROJECT_ROOT, "static")}),
(r'^media/(?P<path>.*)$', 'django.views.static.serve', {'document_root': join(settings.PROJECT_ROOT, "media")}),
# #
) )

View File

@ -1,4 +1,4 @@
Django==1.3 Django==1.4.1
RapidSMS==0.9.6a RapidSMS==0.9.6a
-e git://github.com/schuyler/arrest.git@0017837a45bcb31786f953fba976d454ae684ecc#egg=arrest-dev -e git://github.com/schuyler/arrest.git@0017837a45bcb31786f953fba976d454ae684ecc#egg=arrest-dev
chardet==1.0.1 chardet==1.0.1