From 992f25d08ea2b5a6438ccc792a5c723b8a72f674 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期五, 06 八月 2021 18:19:39 +0800
Subject: [PATCH] 2021-08-06

---
 src/menu/components/card/cardcellcomponent/dragaction/card.jsx |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/src/menu/components/card/cardcellcomponent/dragaction/card.jsx b/src/menu/components/card/cardcellcomponent/dragaction/card.jsx
index 9982b08..ce5e4d4 100644
--- a/src/menu/components/card/cardcellcomponent/dragaction/card.jsx
+++ b/src/menu/components/card/cardcellcomponent/dragaction/card.jsx
@@ -141,6 +141,12 @@
           {`${card.prefix || ''}${moment().format(card.dateFormat)}${card.postfix || ''}`}
         </div>
       )
+    } else if (card.eleType === 'formula') {
+      return (
+        <div className="ant-mk-date">
+          {`${card.prefix || ''}${card.formula}${card.postfix || ''}`}
+        </div>
+      )
     }
   }
 
@@ -158,7 +164,7 @@
         <Icon className="copy" title="澶嶅埗" type="copy" onClick={() => copyCard(id)} />
         <Icon className="close" title="鍒犻櫎" type="close" onClick={() => delCard(id)} />
         <Icon className="style" title="璋冩暣鏍峰紡" onClick={() => changeStyle(id)} type="font-colors" />
-        {['text', 'number', 'slider', 'sequence'].includes(card.eleType) ? <MarkColumn columns={fields} type={card.eleType} marks={card.marks} onSubmit={(vals) => updateMarks({...card, marks: vals})} /> : null }
+        {['text', 'number', 'slider', 'sequence', 'formula'].includes(card.eleType) ? <MarkColumn columns={fields} type={card.eleType} marks={card.marks} onSubmit={(vals) => updateMarks({...card, marks: vals})} /> : null }
       </div>
     } trigger="hover">
       <div ref={node => drag(drop(node))} className={'ant-col card-cell ant-col-' + card.width}>

--
Gitblit v1.8.0