Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit a16e060

Browse files
committed
Added framework configuration missed
1 parent da3995a commit a16e060

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

‎tutorial/settings.py‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,3 +123,11 @@
123123
# https://docs.djangoproject.com/en/1.9/howto/static-files/
124124

125125
STATIC_URL = '/static/'
126+
127+
REST_FRAMEWORK = {
128+
# Use Django's standard `django.contrib.auth` permissions,
129+
# or allow read-only access for unauthenticated users.
130+
'DEFAULT_PERMISSION_CLASSES': [
131+
'rest_framework.permissions.DjangoModelPermissionsOrAnonReadOnly'
132+
]
133+
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /