From dbf30d9cf36e5356e12e8447662ead83edad396e Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期六, 11 三月 2023 17:50:28 +0800
Subject: [PATCH] Merge branch 'develop'

---
 src/templates/subtableconfig/index.jsx |   30 +++---------------------------
 1 files changed, 3 insertions(+), 27 deletions(-)

diff --git a/src/templates/subtableconfig/index.jsx b/src/templates/subtableconfig/index.jsx
index 37ec63e..c47ca6d 100644
--- a/src/templates/subtableconfig/index.jsx
+++ b/src/templates/subtableconfig/index.jsx
@@ -59,7 +59,6 @@
     delActions: [],          // 鍒犻櫎鎸夐挳鍒楄〃
     copyActions: [],         // 澶嶅埗鎸夐挳缁�
     tabviews: [],            // 鎵�鏈夋爣绛鹃〉
-    thawButtons: [],         // 宸查�夋嫨瑕佽В鍐荤殑鎸夐挳
     activeKey: '0',          // 榛樿灞曞紑鍩烘湰淇℃伅
     chartview: null,         // 褰撳墠瑙嗗浘
     openEdition: '',         // 缂栬緫鐗堟湰鏍囪锛岄槻姝㈠浜烘搷浣�
@@ -285,7 +284,7 @@
    * @description 鏍囩椤典繚瀛�
    */
   submitConfig = () => {
-    const { delActions, thawButtons, openEdition } = this.state
+    const { delActions, openEdition } = this.state
     let _config = fromJS(this.state.config).toJS()
     let copyreg = /\d{4}-\d{2}-\d{2}\s\d{2}:\d{2}:\d{2}$/ig
 
@@ -478,26 +477,7 @@
     }).then(resp => {
       if (resp === false) return
 
-      if (thawButtons.length > 0) {
-        let defers = thawButtons.map(item => {
-          return new Promise((resolve) => {
-            Api.getSystemConfig({
-              func: 'sPC_MainMenu_ReDel',
-              MenuID: item
-            }).then(res => {
-              if (res.status) {
-                resolve('')
-              } else {
-                resolve(res.message)
-              }
-            })
-          })
-        })
-
-        return Promise.all(defers)
-      } else {
-        return true
-      }
+      return true
     }).then(res => {
       if (res === true || res === false) return res
 
@@ -510,9 +490,6 @@
         })
         return false
       } else {
-        this.setState({
-          thawButtons: []
-        })
         return true
       }
     }).then(resp => {
@@ -834,7 +811,6 @@
    */
   updateConfig = (res) => {
     this.setState({
-      thawButtons: res.thawButtons,
       config: res.config
     })
   }
@@ -1023,7 +999,7 @@
               <div>
                 <Versions MenuId={config.uuid} open_edition={openEdition} updateConfig={this.refreshConfig}/>
                 <ReplaceField type="table" config={config} updateConfig={this.updateconfig}/>
-                <EditComponent type="table" options={['search', 'form', 'action', 'columns']} config={config} MenuID={config.uuid} thawButtons={this.state.thawButtons} refresh={this.updateConfig}/>
+                <EditComponent type="table" options={['search', 'form', 'action', 'columns']} config={config} refresh={this.updateConfig}/>
                 <Switch className="big" checkedChildren="鍚�" unCheckedChildren="鍋�" checked={config.enabled} onChange={this.onEnabledChange} />
                 <Button type="primary" id="save-config" onClick={this.submitConfig} loading={this.state.menuloading}>淇濆瓨</Button>
                 <Button onClick={this.cancelConfig}>杩斿洖</Button>

--
Gitblit v1.8.0