测试(部署测试):

pull/11/head
李强 2021-03-29 23:37:57 +08:00
parent 438dc5ed57
commit 4587b7551c
1 changed files with 1 additions and 1 deletions

View File

@ -91,7 +91,7 @@ class PermissionModeMiddleware(MiddlewareMixin):
:return:
"""
white_list = ['/admin/logout/', '/admin/login/']
if os.getenv('DEMO_ENV') and not request.method == 'GET' and request.path not in white_list:
if os.getenv('DEMO_ENV') and not request.method in ['GET','OPTIONS'] and request.path not in white_list:
return ErrorJsonResponse(data={}, msg=f'演示模式,不允许操作!')
def has_interface_permission(self, request, method, view_path, user=None):