From 5685341ac4df905f5e2dfba8850100b34d72af20 Mon Sep 17 00:00:00 2001 From: RISE Date: Mon, 2 Feb 2026 16:41:35 +0800 Subject: [PATCH] aaa --- .../finance/purchasingrequisition/add.vue | 29 +++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/src/views/finance/purchasingrequisition/add.vue b/src/views/finance/purchasingrequisition/add.vue index ccba3e2..c28293d 100644 --- a/src/views/finance/purchasingrequisition/add.vue +++ b/src/views/finance/purchasingrequisition/add.vue @@ -1333,9 +1333,20 @@ watch(() => categoryTreeData.value, () => { // 初始化 onMounted(async () => { - // 检测是否在 iframe 中,如果是,则修改 #app 的 overflow 样式以支持滚动 + // 检测是否在 iframe 中,如果是,则修改相关元素的 overflow 样式以支持滚动 if (window.parent !== window) { nextTick(() => { + // 修改 html 和 body + document.documentElement.style.overflow = 'auto'; + document.documentElement.style.height = 'auto'; + document.body.style.overflow = 'auto'; + document.body.style.height = 'auto'; + + // 修改 html 和 body,添加类名 + document.documentElement.classList.add('iframe-mode'); + document.body.classList.add('iframe-mode'); + + // 修改 #app const app = document.getElementById('app'); if (app) { app.style.overflow = 'auto'; @@ -1397,11 +1408,25 @@ onMounted(async () => {