From cce28e33dd7053c5b41d948be342bee4169f4d63 Mon Sep 17 00:00:00 2001
From: "li.yuetong"
Date: Mon, 24 Oct 2022 15:12:29 +0800
Subject: [PATCH] =?UTF-8?q?=E3=80=90=E9=9A=8F=E6=9C=BA=E5=AF=86=E9=92=A5?=
=?UTF-8?q?=E5=8A=A0=E5=AF=86=E8=A7=A3=E5=AF=86=E3=80=91=E6=95=B0=E6=8D=AE?=
=?UTF-8?q?=E6=8A=A5=E8=A1=A8=E9=A1=B5=E9=9D=A2=E5=9C=A8=E6=B5=8F=E8=A7=88?=
=?UTF-8?q?=E5=99=A8=E5=8F=AF=E4=BB=A5=E6=89=93=E5=BC=80=E4=BA=86=EF=BC=8C?=
=?UTF-8?q?=E4=BD=86=E5=9C=A8=E5=BE=AE=E4=BF=A1=E6=88=96=E4=BC=81=E4=B8=9A?=
=?UTF-8?q?=E5=BE=AE=E4=BF=A1=E4=B8=AD=E6=89=93=E5=BC=80=E4=B8=8D=E4=BA=86?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/config/index.js | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/config/index.js b/src/config/index.js
index 2e91e25db..8ee609aac 100644
--- a/src/config/index.js
+++ b/src/config/index.js
@@ -34,7 +34,10 @@ if(localStorage.getItem('apiVersion')){
apiVersion = localStorage.getItem('apiVersion')
}else{
if(ua.match(/MicroMessenger/i) == 'micromessenger'){
- apiVersion = getSearchString('apiVersion')== 'V3'?'v3':'v2';//url中apiVersion没有时,为v2
+ //report/reportList数据报表页面在浏览器可以打开了,但在微信或企业微信中打开不了,接口请求不需要token
+ if(window.location.href.indexOf('apiVersion') > 0){
+ apiVersion = getSearchString('apiVersion')== 'V3'?'v3':'v2';//url中apiVersion没有时,为v2
+ }
}else{
// 在app
if(navigator.userAgent.indexOf('JZG_') > 0){