From e24c707ba13733903c310334fb0bbee1667ca4f6 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期六, 20 八月 2022 22:24:46 +0800
Subject: [PATCH] 2022-08-20

---
 src/tabviews/custom/components/card/cardcellList/index.jsx |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/src/tabviews/custom/components/card/cardcellList/index.jsx b/src/tabviews/custom/components/card/cardcellList/index.jsx
index 00b8a4e..3f84bdc 100644
--- a/src/tabviews/custom/components/card/cardcellList/index.jsx
+++ b/src/tabviews/custom/components/card/cardcellList/index.jsx
@@ -11,6 +11,7 @@
 import MkIcon from '@/components/mk-icon'
 import MKEmitter from '@/utils/events.js'
 import LostPng from '@/assets/img/lost.png'
+import Encrypts from '@/components/encrypts'
 import './index.scss'
 
 const { Paragraph } = Typography
@@ -263,11 +264,12 @@
 
       if (card.datatype === 'static') {
         val = card.value || ''
-        if (/@username@|@fullName@|@mk_city@/ig.test(val)) {
+        if (/@username@|@fullName@|@mk_city@|@bid@/ig.test(val)) {
           let userName = sessionStorage.getItem('User_Name') || ''
           let fullName = sessionStorage.getItem('Full_Name') || ''
           let city = sessionStorage.getItem('city') || ''
-          val = val.replace(/@username@/ig, userName).replace(/@fullName@/ig, fullName).replace(/@mk_city@/ig, city)
+          let bid = data.$$BID || ''
+          val = val.replace(/@username@/ig, userName).replace(/@fullName@/ig, fullName).replace(/@mk_city@/ig, city).replace(/@bid@/ig, bid)
         }
       } else if (data.hasOwnProperty(card.field)) {
         val = data[card.field]
@@ -338,11 +340,14 @@
 
       if (val !== '') {
         let orival = val
+        if (card.format === 'encryption') {
+          val = <Encrypts value={val} />
+        }
         if (card.fixStyle === 'alone') {
           let _s = {fontSize: card.fixSize, color: card.fixColor, marginLeft: card.fixLeft, marginRight: card.fixRight}
           val = <><span style={_s}>{card.prefix || ''}</span>{val}<span style={_s}>{card.postfix || ''}</span></>
         } else {
-          val = `${card.prefix || ''}${val}${card.postfix || ''}`
+          val = <span>{card.prefix || ''}{val}{card.postfix || ''}</span>
         }
         if (card.copyable === 'true') {
           val = <Paragraph copyable={{ text: orival }}>{val}</Paragraph>

--
Gitblit v1.8.0