From 783ab4e467c95e26f7f031151507bd7ad8333a63 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期五, 08 九月 2023 17:34:47 +0800
Subject: [PATCH] 2023-09-08

---
 src/tabviews/zshare/actionList/tabbutton/index.jsx |   17 +++++++----------
 1 files changed, 7 insertions(+), 10 deletions(-)

diff --git a/src/tabviews/zshare/actionList/tabbutton/index.jsx b/src/tabviews/zshare/actionList/tabbutton/index.jsx
index 184f2c8..c34cf31 100644
--- a/src/tabviews/zshare/actionList/tabbutton/index.jsx
+++ b/src/tabviews/zshare/actionList/tabbutton/index.jsx
@@ -146,14 +146,16 @@
       }
     } else if (btn.linkmenu && btn.linkmenu.length > 0) {
       let menuId = btn.linkmenu.slice(-1)[0]
-      let menu = window.GLOB.mkThdMenus.filter(m => m.MenuID === menuId)[0]
+      let menu = null
 
-      if (!menu && btn.MenuName && btn.MenuID) {
+      if (window.GLOB.mkThdMenus.has(menuId)) {
+        menu = {...window.GLOB.mkThdMenus.get(menuId), param: { $BID: primaryId }}
+      } else if (btn.MenuID) {
         menu = {
           MenuID: btn.MenuID,
           MenuName: btn.MenuName,
-          MenuNo: btn.MenuNo,
-          type: btn.tabType
+          type: btn.tabType,
+          param: { $BID: primaryId }
         }
       }
 
@@ -166,12 +168,7 @@
         return
       }
 
-      newtab = {
-        ...menu,
-        param: {
-          $BID: primaryId
-        }
-      }
+      newtab = menu
     }
 
     if (btn.openTab === 'view') {

--
Gitblit v1.8.0