From 41239717c4446af79268b968557274f88a0afaeb Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期六, 15 八月 2020 10:16:07 +0800 Subject: [PATCH] 2020-08-15 --- src/index.js | 31 +++++++++++++++++++------------ 1 files changed, 19 insertions(+), 12 deletions(-) diff --git a/src/index.js b/src/index.js index 88e31d7..d9926a8 100644 --- a/src/index.js +++ b/src/index.js @@ -86,21 +86,28 @@ if (config.mainSystemApi) { let systemApi = config.mainSystemApi - if (/^(http|https):\/\//ig.test(systemApi)) { - let _systemApi = /^(http|https):\/\/[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62}|(:[0-9]{1,4}))+\.?/ig.exec(systemApi) + // if (/^(http|https):\/\//ig.test(systemApi)) { + // let _systemApi = /^(http|https):\/\/[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62}|(:[0-9]{1,4}))+\.?/ig.exec(systemApi) - systemApi = _systemApi ? _systemApi[0] : '' - } else { + // systemApi = _systemApi ? _systemApi[0] : '' + // } else { + // systemApi = '' + // } + + // // 涓氬姟绯荤粺杩炴帴浜戠鏃讹紝鏍煎紡鍖栧鐞� + // if (systemApi && systemApi === /^(http|https):\/\/[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62}|(:[0-9]{1,4}))+\.?/ig.exec(options.cloudServiceApi)[0]) { + // window.GLOB.dataFormat = true + // } + + // if (systemApi) { + // systemApi = systemApi + '/webapi/dostars' + // } + + // 涓氬姟绯荤粺涓嶅厑璁歌繛鎺ヤ簯绔紝涓氬姟绯荤粺杩炴帴sso.mk9h.cn鏃讹紝鏁版嵁铏氬寲澶勭悊 + if (systemApi && systemApi.indexOf('cloud.mk9h.cn') > -1) { systemApi = '' - } - - // 涓氬姟绯荤粺杩炴帴浜戠鏃讹紝鏍煎紡鍖栧鐞� - if (systemApi && systemApi === /^(http|https):\/\/[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62}|(:[0-9]{1,4}))+\.?/ig.exec(options.cloudServiceApi)[0]) { + } else if (systemApi && systemApi.indexOf('sso.mk9h.cn') > -1) { window.GLOB.dataFormat = true - } - - if (systemApi) { - systemApi = systemApi + '/webapi/dostars' } window.GLOB.mainSystemApi = systemApi -- Gitblit v1.8.0