From 4c2a27b9d7604287c4f94c88a84a1f10a44ad39c Mon Sep 17 00:00:00 2001 From: gaoshp <291585735@qq.com> Date: 星期三, 23 七月 2025 20:39:20 +0800 Subject: [PATCH] 123 --- vite.config.mjs | 13 ++++++++++++- 1 files changed, 12 insertions(+), 1 deletions(-) diff --git a/vite.config.mjs b/vite.config.mjs index 3cbb3d4..072c18b 100644 --- a/vite.config.mjs +++ b/vite.config.mjs @@ -1,3 +1,9 @@ +/* + * @Date: 2025-05-27 23:44:41 + * @LastEditors: gaoshp + * @LastEditTime: 2025-06-16 11:56:09 + * @FilePath: /mdmweb/vite.config.mjs + */ import { defineConfig, loadEnv @@ -9,6 +15,11 @@ mode, command }) => { + let target = 'http://120.46.212.231:80'; + if(mode === 'test') { + target = 'http://localhost:80'; + console.log('褰撳墠鐜:',mode,command); + } const env = loadEnv(mode, process.cwd()) const { VITE_APP_ENV, @@ -54,7 +65,7 @@ port: 2888, proxy: { '/api': { - target: 'http://localhost', + target, //target: 'https://saber3.bladex.cn/api', changeOrigin: true, rewrite: path => path.replace(/^\/api/, ''), -- Gitblit v1.9.3