|
1 |
| -import os |
2 |
| - |
3 |
| -DEBUG = True |
4 |
| -TEMPLATE_DEBUG = DEBUG |
5 |
| - |
6 |
| -SITE_ROOT = os.path.dirname(os.path.realpath(__file__)) |
7 |
| - |
8 |
| -ADMINS = ( |
9 |
| - # ('Your Name', 'your_email@example.com'), |
10 |
| -) |
11 |
| - |
12 |
| -MANAGERS = ADMINS |
| 1 | +""" |
| 2 | +Django settings for this project. |
13 | 3 |
|
14 |
| -DATABASES = { |
15 |
| - 'default': { |
16 |
| - 'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'. |
17 |
| - 'NAME': os.path.join(SITE_ROOT, 'db'), # Or path to database file if using sqlite3. |
18 |
| - 'USER': '', # Not used with sqlite3. |
19 |
| - 'PASSWORD': '', # Not used with sqlite3. |
20 |
| - 'HOST': '', # Set to empty string for localhost. Not used with sqlite3. |
21 |
| - 'PORT': '', # Set to empty string for default. Not used with sqlite3. |
22 |
| - } |
23 |
| -} |
| 4 | +Generated by 'django-admin startproject' using Django 1.9. |
24 | 5 |
|
25 |
| -# Local time zone for this installation. Choices can be found here: |
26 |
| -# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name |
27 |
| -# although not all choices may be available on all operating systems. |
28 |
| -# On Unix systems, a value of None will cause Django to use the same |
29 |
| -# timezone as the operating system. |
30 |
| -# If running in a Windows environment this must be set to the same as your |
31 |
| -# system time zone. |
32 |
| -TIME_ZONE = 'America/Chicago' |
| 6 | +For more information on this file, see |
| 7 | +https://docs.djangoproject.com/en/1.9/topics/settings/ |
33 | 8 |
|
34 |
| -# Language code for this installation. All choices can be found here: |
35 |
| -# http://www.i18nguy.com/unicode/language-identifiers.html |
36 |
| -LANGUAGE_CODE = 'en-us' |
| 9 | +For the full list of settings and their values, see |
| 10 | +https://docs.djangoproject.com/en/1.9/ref/settings/ |
| 11 | +""" |
| 12 | +import os |
37 | 13 |
|
38 |
| -SITE_ID = 1 |
| 14 | +# Build paths inside the project like this: os.path.join(BASE_DIR, ...) |
| 15 | +BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) |
39 | 16 |
|
40 |
| -# If you set this to False, Django will make some optimizations so as not |
41 |
| -# to load the internationalization machinery. |
42 |
| -USE_I18N = True |
| 17 | +# Make this unique, and don't share it with anybody. |
| 18 | +SECRET_KEY = '9%$in^gpdaig@v3or_to&_z(=n)3)$f1mr3hf9e#kespy2ajlo' |
43 | 19 |
|
44 |
| -# If you set this to False, Django will not format dates, numbers and |
45 |
| -# calendars according to the current locale |
46 |
| -USE_L10N = True |
| 20 | +DEBUG = True |
47 | 21 |
|
48 | 22 | # Absolute filesystem path to the directory that will hold user-uploaded files.
|
49 | 23 | # Example: "/home/media/media.lawrence.com/media/"
|
|
69 | 43 | # Examples: "http://foo.com/static/admin/", "/static/admin/".
|
70 | 44 | ADMIN_MEDIA_PREFIX = '/static/admin/'
|
71 | 45 |
|
72 |
| -# Additional locations of static files |
73 |
| -STATICFILES_DIRS = ( |
74 |
| - # Put strings here, like "/home/html/static" or "C:/www/django/static". |
75 |
| - # Always use forward slashes, even on Windows. |
76 |
| - # Don't forget to use absolute paths, not relative paths. |
| 46 | +ADMINS = ( |
| 47 | + # ('Your Name', 'your_email@example.com'), |
| 48 | +) |
| 49 | + |
| 50 | +MANAGERS = ADMINS |
| 51 | + |
| 52 | +INSTALLED_APPS = ( |
| 53 | + 'django.contrib.auth', |
| 54 | + 'django.contrib.contenttypes', |
| 55 | + 'django.contrib.sessions', |
| 56 | + 'django.contrib.sites', |
| 57 | + 'django.contrib.messages', |
| 58 | + 'django.contrib.staticfiles', |
| 59 | + 'django.contrib.admin', |
| 60 | + 'fileupload', |
77 | 61 | )
|
78 | 62 |
|
79 | 63 | # List of finder classes that know how to find static files in
|
80 | 64 | # various locations.
|
81 | 65 | STATICFILES_FINDERS = (
|
82 | 66 | 'django.contrib.staticfiles.finders.FileSystemFinder',
|
83 | 67 | 'django.contrib.staticfiles.finders.AppDirectoriesFinder',
|
84 |
| -# 'django.contrib.staticfiles.finders.DefaultStorageFinder', |
85 |
| -) |
86 |
| - |
87 |
| -# Make this unique, and don't share it with anybody. |
88 |
| -SECRET_KEY = '9%$in^gpdaig@v3or_to&_z(=n)3)$f1mr3hf9e#kespy2ajlo' |
89 |
| - |
90 |
| -# List of callables that know how to import templates from various sources. |
91 |
| -TEMPLATE_LOADERS = ( |
92 |
| - 'django.template.loaders.filesystem.Loader', |
93 |
| - 'django.template.loaders.app_directories.Loader', |
94 |
| -# 'django.template.loaders.eggs.Loader', |
95 | 68 | )
|
96 | 69 |
|
97 | 70 | MIDDLEWARE_CLASSES = (
|
|
105 | 78 |
|
106 | 79 | ROOT_URLCONF = 'django-jquery-file-upload.urls'
|
107 | 80 |
|
108 |
| -TEMPLATE_DIRS = ( |
109 |
| - # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates". |
110 |
| - # Always use forward slashes, even on Windows. |
111 |
| - # Don't forget to use absolute paths, not relative paths. |
112 |
| -) |
| 81 | +TEMPLATES = [ |
| 82 | + { |
| 83 | + 'BACKEND': 'django.template.backends.django.DjangoTemplates', |
| 84 | + 'DIRS': [], |
| 85 | + 'APP_DIRS': True, |
| 86 | + 'OPTIONS': { |
| 87 | + 'context_processors': [ |
| 88 | + 'django.template.context_processors.debug', |
| 89 | + 'django.template.context_processors.request', |
| 90 | + 'django.contrib.auth.context_processors.auth', |
| 91 | + 'django.contrib.messages.context_processors.messages', |
| 92 | + ], |
| 93 | + }, |
| 94 | + }, |
| 95 | +] |
113 | 96 |
|
114 |
| -INSTALLED_APPS = ( |
115 |
| - 'django.contrib.auth', |
116 |
| - 'django.contrib.contenttypes', |
117 |
| - 'django.contrib.sessions', |
118 |
| - 'django.contrib.sites', |
119 |
| - 'django.contrib.messages', |
120 |
| - 'django.contrib.staticfiles', |
121 |
| - 'fileupload', |
122 |
| - # Uncomment the next line to enable the admin: |
123 |
| - 'django.contrib.admin', |
124 |
| - # Uncomment the next line to enable admin documentation: |
125 |
| - # 'django.contrib.admindocs', |
126 |
| -) |
| 97 | +DATABASES = { |
| 98 | + 'default': { |
| 99 | + 'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'. |
| 100 | + 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'), # Or path to database file if using sqlite3. |
| 101 | + 'USER': '', # Not used with sqlite3. |
| 102 | + 'PASSWORD': '', # Not used with sqlite3. |
| 103 | + 'HOST': '', # Set to empty string for localhost. Not used with sqlite3. |
| 104 | + 'PORT': '', # Set to empty string for default. Not used with sqlite3. |
| 105 | + } |
| 106 | +} |
| 107 | + |
| 108 | +# Password validation |
| 109 | +# https://docs.djangoproject.com/en/1.9/ref/settings/#auth-password-validators |
| 110 | + |
| 111 | +AUTH_PASSWORD_VALIDATORS = [ |
| 112 | + { |
| 113 | + 'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator', |
| 114 | + }, |
| 115 | + { |
| 116 | + 'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator', |
| 117 | + }, |
| 118 | + { |
| 119 | + 'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator', |
| 120 | + }, |
| 121 | + { |
| 122 | + 'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator', |
| 123 | + }, |
| 124 | +] |
127 | 125 |
|
128 | 126 | # A sample logging configuration. The only tangible logging
|
129 | 127 | # performed by this configuration is to send an email to
|
|
147 | 145 | },
|
148 | 146 | }
|
149 | 147 | }
|
| 148 | + |
| 149 | +# Language code for this installation. All choices can be found here: |
| 150 | +# http://www.i18nguy.com/unicode/language-identifiers.html |
| 151 | +LANGUAGE_CODE = 'en-us' |
| 152 | + |
| 153 | +SITE_ID = 1 |
| 154 | + |
| 155 | +# If you set this to False, Django will make some optimizations so as not |
| 156 | +# to load the internationalization machinery. |
| 157 | +USE_I18N = True |
| 158 | + |
| 159 | +# If you set this to False, Django will not format dates, numbers and |
| 160 | +# calendars according to the current locale |
| 161 | +USE_L10N = True |
0 commit comments