From f6626b05f1275cc2f8ca77f773d4f6a6af1b0a89 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期一, 21 十一月 2022 16:11:55 +0800
Subject: [PATCH] 2022-11-21

---
 src/menu/components/card/prop-card/index.jsx |   49 +++----------------------------------------------
 1 files changed, 3 insertions(+), 46 deletions(-)

diff --git a/src/menu/components/card/prop-card/index.jsx b/src/menu/components/card/prop-card/index.jsx
index 0bec608..5e91a50 100644
--- a/src/menu/components/card/prop-card/index.jsx
+++ b/src/menu/components/card/prop-card/index.jsx
@@ -287,7 +287,6 @@
    * @description 鍗曚釜鍗$墖淇℃伅鏇存柊
    */
   deleteCard = (cell) => {
-    const { appType } = this.state
     let card = fromJS(this.state.card).toJS()
     let _this = this
 
@@ -297,25 +296,6 @@
         card.subcards = card.subcards.filter(item => item.uuid !== cell.uuid)
 
         _this.updateComponent(card)
-
-        if (appType === 'mob') return
-
-        let uuids = []
-
-        cell.elements && cell.elements.forEach(c => {
-          if (c.eleType !== 'button' || (appType === 'pc' && c.OpenType !== 'popview')) return
-
-          uuids.push(c.uuid)
-        })
-        cell.backElements && cell.backElements.forEach(c => {
-          if (c.eleType !== 'button' || (appType === 'pc' && c.OpenType !== 'popview')) return
-
-          uuids.push(c.uuid)
-        })
-
-        if (uuids.length === 0) return
-        
-        MKEmitter.emit('delButtons', uuids)
       },
       onCancel() {}
     })
@@ -324,7 +304,7 @@
   changeStyle = () => {
     const { card } = this.state
 
-    MKEmitter.emit('changeStyle', ['background', 'border', 'padding', 'margin', 'shadow'], card.style, this.getStyle)
+    MKEmitter.emit('changeStyle', ['background', 'border', 'padding', 'margin', 'shadow', 'clear'], card.style, this.getStyle)
   }
 
   getStyle = (style) => {
@@ -401,7 +381,6 @@
     res.setting = res.setting || {}
     res.setting.width = res.setting.width || 6
 
-    let copyBtns = []
     let mobtypes = ['pop', 'prompt', 'exec', 'innerpage', 'funcbutton']
 
     let elements = []
@@ -412,16 +391,7 @@
       } else if (appType === 'mob' && !mobtypes.includes(cell.OpenType)) {
         return
       } else {
-        let _uuid = Utils.getuuid()
-
-        if (cell.OpenType === 'popview') {
-          let _cell = fromJS(cell).toJS()
-          _cell.$originUuid = _cell.uuid
-          _cell.uuid = _uuid
-          copyBtns.push(_cell)
-        }
-
-        cell.uuid = _uuid
+        cell.uuid = Utils.getuuid()
         elements.push(cell)
       }
     })
@@ -438,26 +408,13 @@
         } else if (appType === 'mob' && !mobtypes.includes(cell.OpenType)) {
           return
         } else {
-          let _uuid = Utils.getuuid()
-
-          if (cell.OpenType === 'popview') {
-            let _cell = fromJS(cell).toJS()
-            _cell.$originUuid = _cell.uuid
-            _cell.uuid = _uuid
-            copyBtns.push(_cell)
-          }
-
-          cell.uuid = _uuid
+          cell.uuid = Utils.getuuid()
           backElements.push(cell)
         }
       })
     }
 
     res.backElements = backElements
-
-    if (copyBtns.length > 0) {
-      MKEmitter.emit('copyButtons', copyBtns)
-    }
 
     resolve({status: true})
 

--
Gitblit v1.8.0