Browse Source

chore(config): 更新环境配置切换及修正JSON格式

- 切换开发环境地址配置,启用王的地址,禁用测试直连地址
- 关闭测试环境47.109.84.152地址,启用smqjh.api.zswlgz.com地址
- 注释未使用的请求头设置代码,保留POST/PUT/PATCH设置Content-Type逻辑
- 修正manifest.json末尾多余的括号,保证JSON格式正确
zouzexu 3 days ago
parent
commit
56daae6b01
2 changed files with 7 additions and 4 deletions
  1. 3 0
      src/api/core/instance.ts
  2. 4 4
      src/config/index.ts

+ 3 - 0
src/api/core/instance.ts

@@ -13,6 +13,9 @@ export const alovaInstance = createAlova({
     if (['POST', 'PUT', 'PATCH'].includes(method.type)) {
       method.config.headers['Content-Type'] = 'application/json'
     }
+    // if (['POST', 'PUT', 'PATCH', 'DELETE', 'GET'].includes(method.type)) {
+    //   method.config.headers['X-Tenant-Domain'] = BASE_URL
+    // }
     const { token } = useUserStore()
     method.config.headers.Authorization = token || 'Basic c21xamgtYXBwbGV0OjEyMzQ1Ng=='
     // Add timestamp to prevent caching for GET requests

+ 4 - 4
src/config/index.ts

@@ -8,11 +8,11 @@ const mapEnvVersion = {
   // develop: 'http://192.168.1.253:8080',
   // develop: 'http://192.168.0.19:8080', // 邓
   // develop: 'http://192.168.1.20:8080', // 黄
-  // develop: 'http://192.168.0.11:8080', // 王
+  develop: 'http://192.168.0.11:8080', // 王
   // develop: 'http://192.168.1.21:8080', // 田
   // develop: 'http://74949mkfh190.vicp.fun', // 付
   // develop: 'http://47.109.84.152:8081', // 测试代理
-  develop: 'http://192.168.1.242:8080', // 测试直连
+  // develop: 'http://192.168.1.242:8080', // 测试直连
   // develop: 'https://5ed0f7cc.r9.vip.cpolar.cn',
   // develop: 'https://smqjh.api.zswlgz.com',
   /**
@@ -20,9 +20,9 @@ const mapEnvVersion = {
    */
   // trial: "http://192.168.1.166:8080/jeecg-boot",
   // trial: 'http://192.168.0.157:8080',
-  trial: 'http://47.109.84.152:8081',
+  // trial: 'http://47.109.84.152:8081',
   // trial: 'http://192.168.1.166:8080,
-  // trial: 'https://smqjh.api.zswlgz.com',
+  trial: 'https://smqjh.api.zswlgz.com',
   /**
    * 正式版
    */