浏览代码

[Fix 0000] 修复瓦斯地质页面无法点击文件列表的问题

houzekong 3 月之前
父节点
当前提交
0d1cb57c64
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      src/views/vent/cad/GasGeoViewer.vue

+ 2 - 2
src/views/vent/cad/GasGeoViewer.vue

@@ -33,7 +33,7 @@
     selected.value = treeData.value[0];
   }
 
-  function openFile(id?: string) {
+  function openFile({ id }: Record<string, string> = {}) {
     if (!id) return;
     processFile(id).then((path) => {
       postMessage('MKY_Open_Mxweb', path);
@@ -55,7 +55,7 @@
     registHook('MKY_Open_File_Complete', () => {
       unregistHook('MKY_Open_File_Complete');
       getTreeList().then(() => {
-        openFile(selected.value.id);
+        openFile(selected.value);
       });
     });
   });