12345678910111213141516171819202122232425262728293031323334353637383940 |
- // 本地开发环境
- const local = {
- api: 'https://openapi.dev.bozedu.net/',
- oss: 'https://openapi.dev.bozedu.net/',
- uc: 'https://uc.dev.bozedu.net/',
- }
- // 测试服环境
- const development = {
- web_pc: 'https://dyawdev.bozedu.top/',
- web_mobile: 'https://dyawdevm.bozedu.top/',
- api: 'https://openapi.dev.bozedu.net/',
- oss: 'https://openapi.dev.bozedu.net/',
- uc: 'https://uc.dev.bozedu.net/',
- }
- // // 正式服环境
- const production = {
- web_pc: 'https://dyaw.bozedu.net/',
- web_mobile: 'https://dyawm.bozedu.net/',
- api: 'https://openapi.bozedu.net/',
- oss: 'https://openapi.bozedu.net/',
- uc: 'https://uc.bozedu.net/',
- }
- function isWhich() {
- if (window.location.href.startsWith(development.web_pc) || window.location.href.startsWith(development.web_mobile)) {
- return development
- } else if (window.location.href.startsWith(production.web_pc) || window.location.href.startsWith(production.web_mobile)) {
- return production
- } else {
- return local
- }
- }
- window.GLOBAL_CONFIG = production//isWhich()
- window.RTC_USE = true
|