多环境配置
This commit is contained in:
@@ -12,7 +12,8 @@ let downloadLoadingInstance;
|
||||
export let isRelogin = { show: false };
|
||||
|
||||
axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
|
||||
axios.defaults.headers['X-Tenant-ID'] = '1'
|
||||
// 从环境变量读取租户ID,如果没有则使用默认值'1'
|
||||
axios.defaults.headers['X-Tenant-ID'] = import.meta.env.VITE_APP_TENANT_ID || '1'
|
||||
axios.defaults.headers['Request-Method-Name'] = 'login'
|
||||
// 创建axios实例
|
||||
const service = axios.create({
|
||||
|
||||
Reference in New Issue
Block a user