feat: add signup form
This commit is contained in:
@@ -49,6 +49,8 @@ INSTALLED_APPS = [
|
||||
"allauth",
|
||||
"allauth.account",
|
||||
"allauth.socialaccount",
|
||||
"tailwind",
|
||||
"theme",
|
||||
]
|
||||
|
||||
MIDDLEWARE = [
|
||||
@@ -61,6 +63,7 @@ MIDDLEWARE = [
|
||||
"django.middleware.clickjacking.XFrameOptionsMiddleware",
|
||||
"wagtail.contrib.redirects.middleware.RedirectMiddleware",
|
||||
"allauth.account.middleware.AccountMiddleware",
|
||||
"django.middleware.locale.LocaleMiddleware",
|
||||
]
|
||||
|
||||
ROOT_URLCONF = "kursy.urls"
|
||||
@@ -90,6 +93,18 @@ AUTHENTICATION_BACKENDS = [
|
||||
"allauth.account.auth_backends.AuthenticationBackend",
|
||||
]
|
||||
|
||||
ACCOUNT_SIGNUP_FIELDS = [
|
||||
"first_name*",
|
||||
"last_name*",
|
||||
"email*",
|
||||
"password1*",
|
||||
"password2*",
|
||||
]
|
||||
ACCOUNT_SIGNUP_FORM_CLASS = "kursy.forms.SignUpForm"
|
||||
|
||||
ACCOUNT_LOGIN_METHODS = ["email", "username"]
|
||||
|
||||
|
||||
WSGI_APPLICATION = "kursy.wsgi.application"
|
||||
|
||||
|
||||
@@ -126,7 +141,7 @@ AUTH_PASSWORD_VALIDATORS = [
|
||||
# Internationalization
|
||||
# https://docs.djangoproject.com/en/6.0/topics/i18n/
|
||||
|
||||
LANGUAGE_CODE = "en-us"
|
||||
LANGUAGE_CODE = "pl"
|
||||
|
||||
TIME_ZONE = "UTC"
|
||||
|
||||
@@ -134,6 +149,11 @@ USE_I18N = True
|
||||
|
||||
USE_TZ = True
|
||||
|
||||
LANGUAGES = [
|
||||
("pl", "Polski"),
|
||||
("en", "English"),
|
||||
]
|
||||
|
||||
|
||||
# Static files (CSS, JavaScript, Images)
|
||||
# https://docs.djangoproject.com/en/6.0/howto/static-files/
|
||||
@@ -201,3 +221,5 @@ WAGTAILDOCS_EXTENSIONS = [
|
||||
"xlsx",
|
||||
"zip",
|
||||
]
|
||||
|
||||
TAILWIND_APP_NAME = "theme"
|
||||
|
||||
Reference in New Issue
Block a user