From 31ec63f0419895876cbaba99637a884a32d33d0d Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期三, 01 九月 2021 10:31:45 +0800
Subject: [PATCH] 2021-09-01

---
 src/templates/sharecomponent/actioncomponent/index.jsx |   27 ++++++++-------------------
 1 files changed, 8 insertions(+), 19 deletions(-)

diff --git a/src/templates/sharecomponent/actioncomponent/index.jsx b/src/templates/sharecomponent/actioncomponent/index.jsx
index 37ef9f8..50cdb74 100644
--- a/src/templates/sharecomponent/actioncomponent/index.jsx
+++ b/src/templates/sharecomponent/actioncomponent/index.jsx
@@ -14,6 +14,7 @@
 import ActionForm from './actionform'
 import CreateFunc from '@/templates/zshare/createfunc'
 import CreateInterface from '@/templates/zshare/createinterface'
+import { updateForm } from '@/utils/utils-update.js'
 import DragElement from './dragaction'
 import './index.scss'
 
@@ -143,7 +144,7 @@
     if (usefulFields) {
       try {
         usefulFields = JSON.parse(usefulFields)
-      } catch {
+      } catch (e) {
         usefulFields = []
       }
     } else {
@@ -307,7 +308,7 @@
               _LongParam.setting.title = btn.label
               _LongParam = window.btoa(window.encodeURIComponent(JSON.stringify(_LongParam)))
               _temp = 'Modal'
-            } catch {
+            } catch (e) {
               console.warn('Stringify Failure')
               _temp = ''
             }
@@ -327,7 +328,7 @@
               })
               _LongParam = window.btoa(window.encodeURIComponent(JSON.stringify(_LongParam)))
               _temp = 'FormTab'
-            } catch {
+            } catch (e) {
               console.warn('Stringify Failure')
               _temp = ''
             }
@@ -521,7 +522,7 @@
       btnParam.secretkey = Utils.encrypt(btnParam.LText, btnParam.timestamp)
 
       _LongParam = window.btoa(window.encodeURIComponent(JSON.stringify(_tab)))
-    } catch {
+    } catch (e) {
       console.warn('Stringify Failure')
       _LongParam = ''
       _resolve('save')
@@ -744,19 +745,12 @@
             }
 
             if (_LongParam) {
-              let fields = []
-              if (_LongParam.groups.length > 0) {
-                _LongParam.groups.forEach(group => {
-                  fields = [...fields, ...group.sublist]
-                })
-              } else {
-                fields = _LongParam.fields
-              }
+              _LongParam = updateForm(_LongParam)
 
               let _param = {
                 funcName: btn.innerFunc,
                 name: _config.setting.tableName || '',
-                fields: fields,
+                fields: _LongParam.fields,
                 menuNo: menu.MenuNo
               }
               newLText = Utils.formatOptions(FuncUtils.getfunc(_param, btn, menu, _config))
@@ -842,11 +836,7 @@
     if (!el.origin && (el.OpenType === 'pop' || el.execMode === 'pop' || el.OpenType === 'popview' || (el.OpenType === 'tab' && el.tabTemplate === 'FormTab'))) {
       this.props.setSubConfig(el)
     } else {
-      notification.warning({
-        top: 92,
-        message: '姝ゆ寜閽棤瀛愰厤缃」锛�',
-        duration: 5
-      })
+      this.handleAction(el)
     }
   }
 
@@ -915,7 +905,6 @@
           visible={profVisible}
           width={'75vw'}
           maskClosable={false}
-          style={{minWidth: '900px', maxWidth: '1200px'}}
           okText={dict['model.submit']}
           onOk={this.verifySubmit}
           onCancel={() => { this.setState({ profVisible: false }) }}

--
Gitblit v1.8.0