From 3193df5faaacb0fe903ce993b16319276528524f Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期一, 06 七月 2020 23:14:17 +0800
Subject: [PATCH] 2020-07-06

---
 src/tabviews/zshare/actionList/tabbutton/index.jsx |   46 +++++++++++++++++++++++++++++++++++-----------
 1 files changed, 35 insertions(+), 11 deletions(-)

diff --git a/src/tabviews/zshare/actionList/tabbutton/index.jsx b/src/tabviews/zshare/actionList/tabbutton/index.jsx
index dab08e7..acfd936 100644
--- a/src/tabviews/zshare/actionList/tabbutton/index.jsx
+++ b/src/tabviews/zshare/actionList/tabbutton/index.jsx
@@ -74,17 +74,41 @@
       primaryId = data[0][setting.primaryKey] || ''
     }
 
-    let newtab = {
-      MenuNo: '',
-      MenuID: btn.uuid,
-      MenuName: btn.label,
-      type: btn.tabTemplate,
-      selected: true,
-      param: {
-        parentId: this.props.MenuID,
-        btn: btn,
-        data: data[0] || null,
-        primaryId: primaryId
+    let newtab = {}
+
+    if (btn.tabTemplate === 'FormTab') {
+      newtab = {
+        MenuNo: '',
+        MenuID: btn.uuid,
+        MenuName: btn.label,
+        type: btn.tabTemplate,
+        selected: true,
+        param: {
+          parentId: this.props.MenuID,
+          btn: btn,
+          data: data[0] || null,
+          primaryId: primaryId
+        }
+      }
+    } else if (btn.tabTemplate === 'ThdMenu') {
+      let _type = 'CommonTable'
+      if (btn.linkThdMenu && btn.linkThdMenu.PageParam) {
+        try {
+          _type = JSON.parse(btn.linkThdMenu.PageParam).Template
+        } catch {
+          _type = 'CommonTable'
+        }
+      }
+
+      newtab = {
+        MenuNo: btn.linkThdMenu.MenuNo,
+        MenuID: btn.linkThdMenu.MenuID,
+        MenuName: btn.linkThdMenu.MenuName,
+        type: _type,
+        selected: true,
+        param: {
+          BID: primaryId
+        }
       }
     }
 

--
Gitblit v1.8.0