From 943b185bc64e950a1b9fdcd206252af1949be22b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B1=9F=E5=BF=97=E9=9B=84?= Date: Tue, 12 Mar 2024 14:19:35 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=8C=BA=E5=88=86=E6=9C=AC=E5=9C=B0?= =?UTF-8?q?=E5=92=8C=E7=BA=BF=E4=B8=8A=E6=89=93=E5=8C=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app.ts | 35 ++++++++++++++++++++++------------- 1 file changed, 22 insertions(+), 13 deletions(-) diff --git a/src/app.ts b/src/app.ts index 9826c18..d155abc 100644 --- a/src/app.ts +++ b/src/app.ts @@ -16,29 +16,38 @@ export function useQiankunStateForSlave() { }; } +const env = process.env.NODE_ENV; + export const qiankun = { apps: [ { name: 'intelligent-file-cabinet', // 盒子管理 - entry: '//localhost:30068/intelligent-file-cabinet/', - props: { - accountInfo: { - username: 'admin', - password: 'test123', - }, - }, - }, - { - name: 'smart-video-analysis', // AI 智能分析仓 - entry: '//localhost:30088/smart-video-analysis/', + entry: + env === 'production' + ? '//localhost:30068/intelligent-file-cabinet/' + : '//localhost:30068/', + props: {}, }, { name: 'algorithm-warehouse', // AI 算法分析 - entry: '//localhost:30078/algorithm-warehouse/', + entry: + env === 'production' + ? '//localhost:30078/smart-video-analysis/' + : '//localhost:30078/', + }, + { + name: 'smart-video-analysis', // AI 智能分析仓 + entry: + env === 'production' + ? '//localhost:30088/algorithm-warehouse/' + : '//localhost:30088/', }, { name: 'communal-facilities-pages', // 物料库 - entry: '//localhost:30098/communal-facilities-pages/', + entry: + env === 'production' + ? '//localhost:30098/communal-facilities-pages/' + : '//localhost:30098/', }, ], lifeCycles: {