aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--servo/migrations/0046_auto_20160209_1458.py26
-rw-r--r--settings.py40
2 files changed, 45 insertions, 21 deletions
diff --git a/servo/migrations/0046_auto_20160209_1458.py b/servo/migrations/0046_auto_20160209_1458.py
new file mode 100644
index 0000000..dddbdae
--- /dev/null
+++ b/servo/migrations/0046_auto_20160209_1458.py
@@ -0,0 +1,26 @@
+# -*- coding: utf-8 -*-
+# Generated by Django 1.9.2 on 2016-02-09 12:58
+from __future__ import unicode_literals
+
+import django.core.validators
+from django.db import migrations, models
+
+
+class Migration(migrations.Migration):
+
+ dependencies = [
+ ('servo', '0045_auto_20151123_2021'),
+ ]
+
+ operations = [
+ migrations.AlterField(
+ model_name='device',
+ name='product_line',
+ field=models.CharField(choices=[(b'IPODCLASSIC', b'iPod Classic'), (b'POWERMAC', b'Power Mac'), (b'APPLETV', b'Apple TV'), (b'IMAC', b'iMac'), (b'OTHER', b'Other Products'), (b'MACBOOKAIR', b'MacBook Air'), (b'DISPLAYS', b'Display'), (b'IPODTOUCH', b'iPod Touch'), (b'MACPRO', b'Mac Pro'), (b'IPODNANO', b'iPod nano'), (b'IPAD', b'iPad'), (b'MACBOOK', b'MacBook'), (b'MACACCESSORY', b'Mac Accessory'), (b'MACMINI', b'Mac mini'), (b'WATCH', b'Apple Watch'), (b'MACBOOKLEGACY', b'MacBook'), (b'SERVERS', b'Server'), (b'BEATS', b'Beats Products'), (b'IPHONE', b'iPhone'), (b'IPHONEACCESSORY', b'iPhone Accessory'), (b'IPODSHUFFLE', b'iPod Shuffle'), (b'MACBOOKPRO', b'MacBook Pro'), (b'IPADACCESSORY', b'iPad Accessory')], default=b'OTHER', max_length=16, verbose_name='Product Line'),
+ ),
+ migrations.AlterField(
+ model_name='user',
+ name='username',
+ field=models.CharField(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 30 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=30, unique=True, validators=[django.core.validators.RegexValidator('^[\\w.@+-]+$', 'Enter a valid username. This value may contain only letters, numbers and @/./+/-/_ characters.')], verbose_name='username'),
+ ),
+ ]
diff --git a/settings.py b/settings.py
index 3734deb..9eb04a1 100644
--- a/settings.py
+++ b/settings.py
@@ -79,13 +79,6 @@ STATICFILES_FINDERS = (
#'django.contrib.staticfiles.finders.DefaultStorageFinder',
)
-
-# List of callables that know how to import templates from various sources.
-TEMPLATE_LOADERS = (
- 'django.template.loaders.app_directories.Loader',
- 'django.template.loaders.filesystem.Loader',
-)
-
MIDDLEWARE_CLASSES = (
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.locale.LocaleMiddleware',
@@ -105,11 +98,25 @@ SESSION_SERIALIZER = 'servo.lib.utils.SessionSerializer'
# Python dotted path to the WSGI application used by Django's runserver.
WSGI_APPLICATION = 'wsgi.application'
-TEMPLATE_DIRS = (
- # Don't forget to use absolute paths, not relative paths.
- os.path.join(APP_DIR, 'templates'),
- os.path.join(BASE_DIR, 'uploads'),
-)
+TEMPLATES = [
+ {
+ 'BACKEND': 'django.template.backends.django.DjangoTemplates',
+ 'APP_DIRS': True,
+ 'DIRS': (
+ os.path.join(APP_DIR, 'templates'),
+ os.path.join(BASE_DIR, 'uploads'),
+ ),
+ 'OPTIONS': {
+ 'context_processors': (
+ 'django.contrib.auth.context_processors.auth',
+ 'django.template.context_processors.static',
+ 'django.template.context_processors.request',
+ 'django.template.context_processors.i18n',
+ 'django.contrib.messages.context_processors.messages',
+ ),
+ }
+ },
+]
INSTALLED_APPS = (
'django.contrib.auth',
@@ -162,15 +169,6 @@ FILE_UPLOAD_HANDLERS = ("django_excel.ExcelMemoryFileUploadHandler",
"django_excel.TemporaryExcelFileUploadHandler",)
SESSION_ENGINE = "django.contrib.sessions.backends.cached_db"
-
-TEMPLATE_CONTEXT_PROCESSORS = (
- "django.contrib.auth.context_processors.auth",
- "django.core.context_processors.static",
- "django.core.context_processors.request",
- "django.core.context_processors.i18n",
- "django.contrib.messages.context_processors.messages",
-)
-
EXEMPT_URLS = []
LOGIN_URL = '/login/'