Mercurial > public > sg101
comparison gpp/settings.py @ 178:d51743322bb2
#56 - Cut over to Django 1.2 messaging system.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Wed, 17 Mar 2010 03:12:05 +0000 |
parents | 776028f4bced |
children | aef00df91165 |
comparison
equal
deleted
inserted
replaced
177:9b63ad1f2ad2 | 178:d51743322bb2 |
---|---|
60 | 60 |
61 # List of Loader classes that know how to import templates from various sources. | 61 # List of Loader classes that know how to import templates from various sources. |
62 TEMPLATE_LOADERS = ( | 62 TEMPLATE_LOADERS = ( |
63 ('django.template.loaders.cached.Loader', ( | 63 ('django.template.loaders.cached.Loader', ( |
64 'django.template.loaders.filesystem.Loader', | 64 'django.template.loaders.filesystem.Loader', |
65 'django.template.loaders.app_directories.Loader', | |
65 )), | 66 )), |
66 ) | 67 ) |
67 | 68 |
68 MIDDLEWARE_CLASSES = ( | 69 MIDDLEWARE_CLASSES = ( |
69 'django.middleware.common.CommonMiddleware', | 70 'django.middleware.common.CommonMiddleware', |
70 'django.contrib.sessions.middleware.SessionMiddleware', | 71 'django.contrib.sessions.middleware.SessionMiddleware', |
72 'django.contrib.messages.middleware.MessageMiddleware', | |
71 'django.contrib.auth.middleware.AuthenticationMiddleware', | 73 'django.contrib.auth.middleware.AuthenticationMiddleware', |
72 'django.contrib.flatpages.middleware.FlatpageFallbackMiddleware', | 74 'django.contrib.flatpages.middleware.FlatpageFallbackMiddleware', |
73 'gpp.forums.middleware.WhosOnline', | 75 'gpp.forums.middleware.WhosOnline', |
74 ) | 76 ) |
75 | 77 |
82 os.path.join(project_path, 'templates'), | 84 os.path.join(project_path, 'templates'), |
83 '/home/brian/coding/python/django/django-elsewhere/elsewhere/templates', | 85 '/home/brian/coding/python/django/django-elsewhere/elsewhere/templates', |
84 ) | 86 ) |
85 | 87 |
86 TEMPLATE_CONTEXT_PROCESSORS = ( | 88 TEMPLATE_CONTEXT_PROCESSORS = ( |
87 "django.contrib.auth.context_processors.auth", | 89 "django.contrib.auth.context_processors.auth", |
88 "django.core.context_processors.debug", | 90 "django.core.context_processors.debug", |
89 "django.core.context_processors.request", | 91 "django.core.context_processors.request", |
90 "django.core.context_processors.media" | 92 "django.core.context_processors.media", |
93 "django.contrib.messages.context_processors.messages", | |
91 ) | 94 ) |
92 | 95 |
93 INSTALLED_APPS = ( | 96 INSTALLED_APPS = ( |
94 'django.contrib.admin', | 97 'django.contrib.admin', |
95 'django.contrib.admindocs', | 98 'django.contrib.admindocs', |
96 'django.contrib.auth', | 99 'django.contrib.auth', |
97 'django.contrib.contenttypes', | 100 'django.contrib.contenttypes', |
101 'django.contrib.flatpages', | |
98 'django.contrib.humanize', | 102 'django.contrib.humanize', |
103 'django.contrib.markup', | |
104 'django.contrib.messages', | |
99 'django.contrib.sessions', | 105 'django.contrib.sessions', |
100 'django.contrib.sites', | 106 'django.contrib.sites', |
101 'django.contrib.markup', | |
102 'django.contrib.flatpages', | |
103 'elsewhere', | 107 'elsewhere', |
104 'tagging', | 108 'tagging', |
105 'accounts', | 109 'accounts', |
106 'bio', | 110 'bio', |
107 'bulletins', | 111 'bulletins', |
130 | 134 |
131 FILE_UPLOAD_PERMISSIONS = 0644 | 135 FILE_UPLOAD_PERMISSIONS = 0644 |
132 DEFAULT_FROM_EMAIL = ADMINS[0][1] | 136 DEFAULT_FROM_EMAIL = ADMINS[0][1] |
133 | 137 |
134 ####################################################################### | 138 ####################################################################### |
139 # Messages | |
140 ####################################################################### | |
141 MESSAGE_STORAGE = 'django.contrib.messages.storage.session.SessionStorage' | |
142 | |
143 ####################################################################### | |
135 # Caching | 144 # Caching |
136 ####################################################################### | 145 ####################################################################### |
137 if local_settings.USE_CACHE: | 146 if local_settings.USE_CACHE: |
138 CACHE_BACKEND = local_settings.CACHE_BACKEND | 147 CACHE_BACKEND = local_settings.CACHE_BACKEND |
139 #CACHE_MIDDLEWARE_SECONDS = local_settings.CACHE_MIDDLEWARE_SECONDS | 148 #CACHE_MIDDLEWARE_SECONDS = local_settings.CACHE_MIDDLEWARE_SECONDS |