|
@@ -15,7 +15,6 @@ from pathlib import Path |
|
|
# Build paths inside the project like this: BASE_DIR / 'subdir'. |
|
|
# Build paths inside the project like this: BASE_DIR / 'subdir'. |
|
|
BASE_DIR = Path(__file__).resolve().parent.parent |
|
|
BASE_DIR = Path(__file__).resolve().parent.parent |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Quick-start development settings - unsuitable for production |
|
|
# Quick-start development settings - unsuitable for production |
|
|
# See https://docs.djangoproject.com/en/4.0/howto/deployment/checklist/ |
|
|
# See https://docs.djangoproject.com/en/4.0/howto/deployment/checklist/ |
|
|
|
|
|
|
|
@@ -27,7 +26,6 @@ DEBUG = True |
|
|
|
|
|
|
|
|
ALLOWED_HOSTS = [] |
|
|
ALLOWED_HOSTS = [] |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Application definition |
|
|
# Application definition |
|
|
|
|
|
|
|
|
INSTALLED_APPS = [ |
|
|
INSTALLED_APPS = [ |
|
@@ -37,7 +35,8 @@ INSTALLED_APPS = [ |
|
|
'django.contrib.sessions', |
|
|
'django.contrib.sessions', |
|
|
'django.contrib.messages', |
|
|
'django.contrib.messages', |
|
|
'django.contrib.staticfiles', |
|
|
'django.contrib.staticfiles', |
|
|
'rest_framework' |
|
|
|
|
|
|
|
|
'rest_framework', |
|
|
|
|
|
'rest_framework.authtoken', |
|
|
] |
|
|
] |
|
|
|
|
|
|
|
|
MIDDLEWARE = [ |
|
|
MIDDLEWARE = [ |
|
@@ -57,6 +56,9 @@ REST_FRAMEWORK = { |
|
|
# or allow read-only access for unauthenticated users. |
|
|
# or allow read-only access for unauthenticated users. |
|
|
'DEFAULT_PERMISSION_CLASSES': [ |
|
|
'DEFAULT_PERMISSION_CLASSES': [ |
|
|
'rest_framework.permissions.DjangoModelPermissionsOrAnonReadOnly' |
|
|
'rest_framework.permissions.DjangoModelPermissionsOrAnonReadOnly' |
|
|
|
|
|
], |
|
|
|
|
|
'DEFAULT_AUTHENTICATION_CLASSES': [ |
|
|
|
|
|
'rest_framework.authentication.BasicAuthentication' |
|
|
] |
|
|
] |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@@ -78,7 +80,6 @@ TEMPLATES = [ |
|
|
|
|
|
|
|
|
WSGI_APPLICATION = 'workx_backend.wsgi.application' |
|
|
WSGI_APPLICATION = 'workx_backend.wsgi.application' |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Database |
|
|
# Database |
|
|
# https://docs.djangoproject.com/en/4.0/ref/settings/#databases |
|
|
# https://docs.djangoproject.com/en/4.0/ref/settings/#databases |
|
|
|
|
|
|
|
@@ -89,7 +90,6 @@ DATABASES = { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Password validation |
|
|
# Password validation |
|
|
# https://docs.djangoproject.com/en/4.0/ref/settings/#auth-password-validators |
|
|
# https://docs.djangoproject.com/en/4.0/ref/settings/#auth-password-validators |
|
|
|
|
|
|
|
@@ -108,7 +108,6 @@ AUTH_PASSWORD_VALIDATORS = [ |
|
|
}, |
|
|
}, |
|
|
] |
|
|
] |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Internationalization |
|
|
# Internationalization |
|
|
# https://docs.djangoproject.com/en/4.0/topics/i18n/ |
|
|
# https://docs.djangoproject.com/en/4.0/topics/i18n/ |
|
|
|
|
|
|
|
@@ -120,7 +119,6 @@ USE_I18N = True |
|
|
|
|
|
|
|
|
USE_TZ = True |
|
|
USE_TZ = True |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Static files (CSS, JavaScript, Images) |
|
|
# Static files (CSS, JavaScript, Images) |
|
|
# https://docs.djangoproject.com/en/4.0/howto/static-files/ |
|
|
# https://docs.djangoproject.com/en/4.0/howto/static-files/ |
|
|
|
|
|
|
|
|