From 123c7e3bda12d75bd64db6b7a18cc5e9ece06735 Mon Sep 17 00:00:00 2001 From: zmister Date: Wed, 8 Sep 2021 00:04:55 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96XSS=E8=BF=87=E6=BB=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app_admin/views.py | 3 ++- app_doc/views.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app_admin/views.py b/app_admin/views.py index eefa44c..62fd373 100644 --- a/app_admin/views.py +++ b/app_admin/views.py @@ -20,6 +20,7 @@ from app_api.auth_app import AppAuth,AppMustAuth # 自定义认证 from app_api.permissions_app import SuperUserPermission # 自定义权限 from app_admin.decorators import superuser_only,open_register from app_doc.models import * +from app_doc.views import jsonXssFilter from app_admin.models import * from app_admin.utils import * from loguru import logger @@ -685,7 +686,7 @@ def admin_doc(request): "code": 0, "msg": "ok", "count": doc_list.count(), - "data": table_data + "data": jsonXssFilter(table_data) } return JsonResponse(resp_data) diff --git a/app_doc/views.py b/app_doc/views.py index 61f07c6..e070582 100644 --- a/app_doc/views.py +++ b/app_doc/views.py @@ -1451,7 +1451,7 @@ def manage_doc(request): "code": 0, "msg": "ok", "count": doc_list.count(), - "data": table_data + "data": jsonXssFilter(table_data) } return JsonResponse(resp_data)