Forráskód Böngészése

No usar cookie sessions ni CSRF checks en views de la api rest

wilitp 3 éve
szülő
commit
0c806499ef
1 módosított fájl, 4 hozzáadás és 0 törlés
  1. 4 0
      app/preports/settings.py

+ 4 - 0
app/preports/settings.py

@@ -131,6 +131,10 @@ STATIC_URL = 'static/'
 
 DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
 
+DEFAULT_AUTHENTICATION_CLASSES = [
+    'rest_framework.authentication.BasicAuthentication'
+]
+
 CLIMA_URL = os.getenv("CLIMA_URL")
 
 CRONJOBS = [