JiangShan-app/env.config.js

45 lines
1.1 KiB
JavaScript
Raw Normal View History

2025-05-22 16:23:08 +08:00
// H5端开发和生产环境协议
let protocalDev = "wss://";
let protocalProd = "wss://";
// 条件编译微信端和移动端使用wxs协议
// #ifdef MP-WEIXIN || APP-PLUS
protocalDev = 'wxs://';
protocalProd = 'wxs://';
// #endif
// 腾讯地图key
let qqmapKey = '4PDBZ-4KQKU-AX6VO-GU7NB-INDZJ-YBFXC';
// 心知天气key
let xinzhiKey = 'SBh45_yy21FU5ErV_';
const CONFIG = {
// 开发环境配置
development: {
officialWebUrl: 'https://iot-xcwl.cn/',
baseUrl: 'https://iot-xcwl.cn/prod-api/',
mqttServer: protocalProd + 'iot-xcwl.cn/mqtt',
decoderUrl: 'https://iot-xcwl.cn/',
qqmapKey,
xinzhiKey,
},
// 生产环境配置
production: {
officialWebUrl: 'https://js.xcwl-aiot.cn/',
baseUrl: 'https://js.xcwl-aiot.cn/prod-api/',
mqttServer: protocalDev + 'js.xcwl-aiot.cn/mqtt',
decoderUrl: 'https://js.xcwl-aiot.cn/',
qqmapKey,
xinzhiKey,
// officialWebUrl: 'https://fastbee.cn/',
// baseUrl: 'https://iot.fastbee.cn/prod-api/',
// mqttServer: protocalProd + 'iot.fastbee.cn/mqtt',
// decoderUrl: 'https://iot.fastbee.cn/',
// qqmapKey,
// xinzhiKey,
}
}
export default CONFIG[process.env.NODE_ENV];