From 944730f2794b87aa053f53084f0d082d4af6fd41 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 29 十月 2020 19:03:30 +0800
Subject: [PATCH] 2020-10-29

---
 src/tabviews/zshare/actionList/normalbutton/index.jsx |   16 ++++++++++------
 1 files changed, 10 insertions(+), 6 deletions(-)

diff --git a/src/tabviews/zshare/actionList/normalbutton/index.jsx b/src/tabviews/zshare/actionList/normalbutton/index.jsx
index bae524d..5456b53 100644
--- a/src/tabviews/zshare/actionList/normalbutton/index.jsx
+++ b/src/tabviews/zshare/actionList/normalbutton/index.jsx
@@ -22,9 +22,9 @@
     show: PropTypes.any,              // 鎸夐挳鏄剧ず鏍峰紡鎺у埗
     BID: PropTypes.string,            // 涓昏〃ID
     BData: PropTypes.any,             // 涓昏〃鏁版嵁
+    style: PropTypes.any,             // 鎸夐挳鏍峰紡
     selectedData: PropTypes.any,      // 瀛愯〃涓�夋嫨鏁版嵁
     Tab: PropTypes.any,               // 濡傛灉褰撳墠鍏冪礌涓烘爣绛炬椂锛宼ab涓烘爣绛句俊鎭�
-    MenuID: PropTypes.string,         // 鑿滃崟ID
     btn: PropTypes.object,            // 鎸夐挳
     columns: PropTypes.any,           // 瀛楁鍒�
     setting: PropTypes.any,           // 椤甸潰閫氱敤璁剧疆
@@ -176,8 +176,10 @@
       this.execSubmit(data, () => { this.setState({loading: false})})
     } else if (btn.OpenType === 'pop') {
       this.updateStatus('start')
+
       this.setState({
-        tabledata: data
+        tabledata: data,
+        btnconfig: btn.modal ? btn.modal : this.state.btnconfig
       }, () => {
         this.improveAction()
       })
@@ -737,7 +739,7 @@
       this.sendMessage()
     }
 
-    this.props.updateStatus('refresh', btn.execSuccess)
+    this.props.updateStatus('refresh', btn.execSuccess, btn)
   }
 
   sendMessage = () => {
@@ -879,7 +881,7 @@
       loading: false
     })
 
-    this.props.updateStatus('refresh', btn.execError)
+    this.props.updateStatus('refresh', btn.execError, btn)
   }
 
   /**
@@ -1164,12 +1166,13 @@
   }
 
   render() {
-    const { btn, show } = this.props
+    const { btn, show, style } = this.props
     const { loadingNumber, loading } = this.state
 
-    if (show === 'actionList') {
+    if (show === 'actionList' || show === 'button') {
       return <div style={{display: 'inline-block'}} onClick={(e) => e.stopPropagation()}>
         <Button
+          style={style}
           icon={btn.icon}
           loading={loading}
           className={'mk-btn mk-' + btn.class}
@@ -1192,6 +1195,7 @@
       return <div style={{display: 'inline-block'}} onClick={(e) => e.stopPropagation()}>
         <Button
           type="link"
+          style={style}
           loading={loading}
           icon={show === 'text' ? '' : (btn.icon || '')}
           onClick={() => {this.actionTrigger()}}

--
Gitblit v1.8.0