diff --git a/src/utils/tools.js b/src/utils/tools.js index bc31e22..6bfb349 100644 --- a/src/utils/tools.js +++ b/src/utils/tools.js @@ -227,21 +227,21 @@ export async function generateSign(config, udid, timestamp) { const method = config.method?.toUpperCase() || 'GET'; // 获取host(从baseURL或当前域名) 本地启动要求host为xsynergy.gxtech.ltd - let host = 'xsynergy.gxtech.ltd'; - // let host = ''; - // // console.log('请求配置:', config.baseURL) - // if (config.baseURL) { - // try { - // const urlObj = new URL(config.baseURL); - // // console.log('解析baseURL成功:', urlObj); - // host = urlObj.host; - // } catch (e) { - // // console.log('解析baseURL失败,使用window.location.host:', window.location); - // host = window.location.host; - // } - // } else { - // host = window.location.host; - // } + // let host = 'xsynergy.gxtech.ltd'; + let host = ''; + // console.log('请求配置:', config.baseURL) + if (config.baseURL) { + try { + const urlObj = new URL(config.baseURL); + // console.log('解析baseURL成功:', urlObj); + host = urlObj.host; + } catch (e) { + // console.log('解析baseURL失败,使用window.location.host:', window.location); + host = window.location.host; + } + } else { + host = window.location.host; + } // console.log('请求host:', host); diff --git a/xSynergy-manage.zip b/xSynergy-manage.zip new file mode 100644 index 0000000..8950778 Binary files /dev/null and b/xSynergy-manage.zip differ