Create app settings

stream
Laurent 2 years ago
parent 84f1f7209c
commit 903ca3123c
  1. 13
      padelclub_backend/settings.py
  2. 13
      padelclub_backend/settings_app.py

@ -106,18 +106,6 @@ AUTH_PASSWORD_VALIDATORS = [
},
]
REST_FRAMEWORK = {
# Use Django's standard `django.contrib.auth` permissions,
# or allow read-only access for unauthenticated users.
'DEFAULT_AUTHENTICATION_CLASSES': [
'rest_framework.authentication.BasicAuthentication',
'rest_framework.authentication.SessionAuthentication',
],'DEFAULT_PERMISSION_CLASSES': [
# 'rest_framework.permissions.DjangoModelPermissionsOrAnonReadOnly'
'rest_framework.permissions.IsAdminUser',
]
}
# Internationalization
# https://docs.djangoproject.com/en/4.1/topics/i18n/
@ -155,3 +143,4 @@ REST_FRAMEWORK = {
}
from .settings_local import *
from .settings_app import *

@ -0,0 +1,13 @@
# Rest Framework configuration
REST_FRAMEWORK = {
# Use Django's standard `django.contrib.auth` permissions,
# or allow read-only access for unauthenticated users.
# 'DEFAULT_PERMISSION_CLASSES': [
# 'rest_framework.permissions.IsAuthenticated',
# ],
'DEFAULT_AUTHENTICATION_CLASSES': [
'rest_framework.authentication.BasicAuthentication',
'rest_framework.authentication.TokenAuthentication',
]
}
Loading…
Cancel
Save