From 251328d45cab911367aff8807167d6d2065fd55a Mon Sep 17 00:00:00 2001 From: jiangzhixiong <710328466@qq.com> Date: Fri, 15 Mar 2024 16:52:29 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E4=B8=BB=E5=AD=90?= =?UTF-8?q?=E5=BA=94=E7=94=A8=E9=93=BE=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app.ts | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/app.ts b/src/app.ts index 9826c18..5100af2 100644 --- a/src/app.ts +++ b/src/app.ts @@ -16,11 +16,13 @@ export function useQiankunStateForSlave() { }; } +const hostname = location.hostname; + export const qiankun = { apps: [ { name: 'intelligent-file-cabinet', // 盒子管理 - entry: '//localhost:30068/intelligent-file-cabinet/', + entry: `//${hostname}:30068/intelligent-file-cabinet/`, props: { accountInfo: { username: 'admin', @@ -30,15 +32,15 @@ export const qiankun = { }, { name: 'smart-video-analysis', // AI 智能分析仓 - entry: '//localhost:30088/smart-video-analysis/', + entry: `//${hostname}:30088/smart-video-analysis/`, }, { name: 'algorithm-warehouse', // AI 算法分析 - entry: '//localhost:30078/algorithm-warehouse/', + entry: `//${hostname}:30078/algorithm-warehouse/`, }, { name: 'communal-facilities-pages', // 物料库 - entry: '//localhost:30098/communal-facilities-pages/', + entry: `//${hostname}:30098/communal-facilities-pages/`, }, ], lifeCycles: {