From adc5a4d5fe46400f0fa1c35a106b8dcea417cd67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B2=A1=E5=A4=8D=E4=B9=A0?= <2353956224@qq.com> Date: Thu, 12 Feb 2026 13:03:52 +0800 Subject: [PATCH] =?UTF-8?q?yolo=E5=95=86=E5=BA=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/layout/WorkbenchLayout.vue | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/layout/WorkbenchLayout.vue b/src/layout/WorkbenchLayout.vue index 6269465..6c285e6 100644 --- a/src/layout/WorkbenchLayout.vue +++ b/src/layout/WorkbenchLayout.vue @@ -50,6 +50,14 @@ sports_esports PK 工作台 + + +
@@ -129,6 +137,16 @@
+ + +
+ +
@@ -154,6 +172,7 @@ const emit = defineEmits(['logout', 'go-back', 'stop-all']) const currentView = ref('tk') // Default Tab const autoDmMode = ref('config') // Default Sub-state: 'config' or 'browser' +const adminLoaded = ref(false) // 懒加载:首次切换到管理后台时才加载 iframe const handleGoToBrowser = async () => { autoDmMode.value = 'browser' @@ -175,6 +194,11 @@ const handleStopAll = () => { // Watch for view changes to manage native Electron BrowserViews watch(currentView, async (newVal, oldVal) => { + // 懒加载管理后台 iframe + if (newVal === 'shop' && !adminLoaded.value) { + adminLoaded.value = true + } + if (!isElectron()) return if (newVal === 'auto_dm' && autoDmMode.value === 'browser') {