diff --git a/server/server/urls.py b/server/server/urls.py index 11f10bb..acaa3d7 100644 --- a/server/server/urls.py +++ b/server/server/urls.py @@ -67,4 +67,5 @@ urlpatterns = [ path('api/supervision/', include('apps.supervision.urls')), path('api/docs/', include_docs_urls(title="接口文档",authentication_classes=[], permission_classes=[])), path('api/', include(router.urls)), + url(r'^api/static/(?P.*)$', serve,{'document_root': settings.STATIC_ROOT}, name='static'), ] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)