diff --git a/backend/base/settings.py b/backend/base/settings.py index f9e401c..9c63326 100644 --- a/backend/base/settings.py +++ b/backend/base/settings.py @@ -28,6 +28,10 @@ ALLOWED_HOSTS: list[str] = ["*", "http://localhost", "localhost"] +CSRF_TRUSTED_ORIGINS = [ + 'http://localhost', 'http://localhost:80', 'http://localhost:4200', 'http://localhost:6969' +] + INSTALLED_APPS = [ # 'daphne', "django.contrib.admin", @@ -47,7 +51,7 @@ "django.middleware.security.SecurityMiddleware", "django.contrib.sessions.middleware.SessionMiddleware", "django.middleware.common.CommonMiddleware", - # "django.middleware.csrf.CsrfViewMiddleware", + "django.middleware.csrf.CsrfViewMiddleware", "django.contrib.auth.middleware.AuthenticationMiddleware", "django.contrib.messages.middleware.MessageMiddleware", "django.middleware.clickjacking.XFrameOptionsMiddleware", @@ -55,10 +59,11 @@ ] CORS_ORIGIN_ALLOW_ALL = True -# CORS_ORIGIN_WHITELIST = ("http://localhost:5173",) +CORS_ALLOW_ALL_ORIGINS = True ASGI_APPLICATION = "api.routing.application" -CHANNEL_LAYERS = {"default": {"BACKEND": "channels.layers.InMemoryChannelLayer"}} +CHANNEL_LAYERS = {"default": { + "BACKEND": "channels.layers.InMemoryChannelLayer"}} MESSAGE_STORAGE = "django.contrib.messages.storage.cookie.CookieStorage" diff --git a/frontend/index.html b/frontend/index.html index 4a61806..35d9324 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -1,16 +1,16 @@ -
- - - - - -