Files
template-5/config/env.ts
赵忠林 5612f40818 refactor(doctor): 重构医生模块为经销商模块并优化相关功能
- 将 doctor 目录重命名为 dealer 目录
- 更新页面标题从'会员注册'为'注册会员'
- 删除银行卡管理、患者报备和订单消息功能
- 重命名组件 AddDoctor 为 AddUserAddress
- 添加用户角色管理和默认角色写入逻辑
- 优化注册成功后跳转至用户中心页面
- 更新应用配置中的页面路径和子包结构
- 添加经销商资金管理、团队管理和二维码推广功能
- 更新租户信息配置,增加租户名称和版权信息
- 优化文章列表组件的类型定义和渲染方式
- 修复广告轮播图数据加载和图片兼容性问题
2026-02-02 19:59:50 +08:00

44 lines
936 B
TypeScript

// 环境变量配置
export const ENV_CONFIG = {
// 开发环境
development: {
// API_BASE_URL: 'http://127.0.0.1:9200/api',
API_BASE_URL: 'https://mp-api.websoft.top/api',
APP_NAME: '开发环境',
DEBUG: 'true',
},
// 生产环境
production: {
API_BASE_URL: 'https://mp-api.websoft.top/api',
APP_NAME: '网宿软件',
DEBUG: 'false',
},
// 测试环境
test: {
API_BASE_URL: 'https://mp-api.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()