From 11571c20450b0989d199b9868e890d10446b9610 Mon Sep 17 00:00:00 2001 From: kuaifan Date: Mon, 8 May 2023 23:09:59 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20Windows=2010=20=E4=BB=A5=E4=B8=8B?= =?UTF-8?q?=E4=B8=8D=E6=94=AF=E6=8C=81=E5=8A=A0=E5=AF=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- resources/assets/js/store/actions.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/resources/assets/js/store/actions.js b/resources/assets/js/store/actions.js index 9a3be1d60..a764ec0f9 100644 --- a/resources/assets/js/store/actions.js +++ b/resources/assets/js/store/actions.js @@ -137,6 +137,15 @@ export default { ], true)) { params.encrypt = true } + if (params.encrypt) { + const userAgent = window.navigator.userAgent; + if (/Windows NT 5.1|Windows XP/.test(userAgent) + || userAgent.indexOf("Windows NT 6.0") !== -1 + || userAgent.indexOf("Windows NT 6.1") !== -1 + || userAgent.indexOf("Windows NT 6.2") !== -1) { + params.encrypt = false // 是 Windows Xp, Vista, 7, 8 系统,不支持加密 + } + } params.url = $A.apiUrl(params.url) params.data = $A.date2string(params.data) //