Add signup and login pages

This commit is contained in:
2024-06-29 19:29:47 -04:00
parent 3b0746ed83
commit 589d109cec
8 changed files with 75 additions and 3 deletions

View File

@@ -55,7 +55,7 @@ ROOT_URLCONF = 'django_customUser.urls'
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [],
'DIRS': [BASE_DIR / "templates"],
'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
@@ -122,3 +122,6 @@ STATIC_URL = 'static/'
# https://docs.djangoproject.com/en/5.0/ref/settings/#default-auto-field
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
LOGIN_REDIRECT_URL = "home"
LOGOUT_REDIRECT_URL = "home"

View File

@@ -15,8 +15,12 @@ Including another URLconf
2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
"""
from django.contrib import admin
from django.urls import path
from django.urls import path, include
from django.views.generic.base import TemplateView
urlpatterns = [
path('', TemplateView.as_view(template_name="home.html"), name="home"),
path('admin/', admin.site.urls),
path('accounts/', include("accounts.urls")),
path('accounts/', include("django.contrib.auth.urls")),
]