Files
template-10560/config/env.ts
赵忠林 92662a869b feat(dealer/team): 实现经销商团队多层级查看功能
- 添加层级栈管理,支持返回上一层功能
- 增加加载状态显示
- 优化团队成员列表展示,增加可查看下级成员的提示
- 添加返回上一层按钮
- 修复了一些与团队成员数据相关的小问题
2025-09-05 23:36:13 +08:00

43 lines
897 B
TypeScript

// 环境变量配置
export const ENV_CONFIG = {
// 开发环境
development: {
API_BASE_URL: 'https://cms-api.websoft.top/api',
APP_NAME: '开发环境',
DEBUG: 'true',
},
// 生产环境
production: {
API_BASE_URL: 'https://cms-api.websoft.top/api',
APP_NAME: '九运售电云',
DEBUG: 'false',
},
// 测试环境
test: {
API_BASE_URL: 'https://cms-api.s209.websoft.top/api',
APP_NAME: '测试环境',
DEBUG: 'true',
}
}
// 获取当前环境配置
export function getEnvConfig() {
const env = process.env.NODE_ENV || 'development'
if (env === 'production') {
return ENV_CONFIG.production
} else { // @ts-ignore
if (env === 'test') {
return ENV_CONFIG.test
} else {
return ENV_CONFIG.development
}
}
}
// 导出环境变量
export const {
API_BASE_URL,
APP_NAME,
DEBUG
} = getEnvConfig()