部分问题修复
This commit is contained in:
@@ -25,8 +25,8 @@ export function returnBaseUrl(param) {
|
||||
env,
|
||||
apiType
|
||||
} = param
|
||||
if(!env){
|
||||
env=ENV
|
||||
if (!env) {
|
||||
env = ENV
|
||||
}
|
||||
console.log('env', env);
|
||||
console.log('apiType', apiType);
|
||||
@@ -70,6 +70,23 @@ export function returnBaseUrl(param) {
|
||||
|
||||
}
|
||||
|
||||
function returnWss(env) {
|
||||
// #ifdef H5
|
||||
if (env === 'test') {
|
||||
return 'http://192.168.1.42:2348'
|
||||
} else {
|
||||
return 'https://czgeatws.sxczgkj.com/wss'
|
||||
}
|
||||
// #endif
|
||||
// #ifndef H5
|
||||
if (env === 'test') {
|
||||
return 'ws://192.168.1.42:2348'
|
||||
} else {
|
||||
return 'wss://czgeatws.sxczgkj.com/wss'
|
||||
}
|
||||
// #endif
|
||||
|
||||
}
|
||||
|
||||
|
||||
const appConfig = {
|
||||
@@ -85,7 +102,7 @@ const appConfig = {
|
||||
env: {},
|
||||
|
||||
// wss: "wss://sockets.sxczgkj.com/wss", //测试环境
|
||||
wss: "wss://czgeatws.sxczgkj.com/wss", //正式环境
|
||||
wss: returnWss(), //正式环境
|
||||
// 环境变量常量
|
||||
ENV_ENUM: {
|
||||
DEVELOPMENT: 'development', // 本地调试地址
|
||||
|
||||
Reference in New Issue
Block a user