liuQiang il y a 1 an
Parent
commit
92af1d2073
1 fichiers modifiés avec 5 ajouts et 5 suppressions
  1. 5 5
      src/layout/indexCommon.vue

+ 5 - 5
src/layout/indexCommon.vue

@@ -706,10 +706,7 @@ const addFileTab = (data, bool,copy,history,fileId) => {
             par.show = true
             thisData.docId = "";
             editableTabsValue.value = par.id// 新建时标签跳转
-            setTimeout(() => {
-
               iframeSize(par.id,history)
-            }, 1000);
           }
         } else {
           par.show = false
@@ -877,13 +874,16 @@ const closeFileTab = (item, index, e) => {
 };
 // 控制iframe大小
 const iframeSize = (par,history) => {
+  // console.log('执行ifSize',par);
   const outIframe = document.getElementById("iframe" + par.id);
   const inIframe =
     outIframe.contentDocument.getElementsByTagName("iframe")[0];
   if(inIframe==null){
+    // console.log('没有inF');
     setTimeout(() => {
-      iframeSize(id)
-    }, 1000);
+      // console.log('==============');
+      iframeSize(par)
+    }, 200);
     return
   }
   console.log('outIframe', outIframe.parentElement);