From 12a11a4d6140fb2a837ce5c294fb79377fb02907 Mon Sep 17 00:00:00 2001
From: wangjiahao <1522128093@qq.com>
Date: Thu, 20 Jun 2024 18:05:06 +0800
Subject: [PATCH] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF=E3=80=81?=
=?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=A4=A7=E5=B1=8F):=20=E5=AF=8C=E6=96=87?=
=?UTF-8?q?=E6=9C=AC=E6=94=AF=E6=8C=81=E9=98=88=E5=80=BC=E8=AE=BE=E7=BD=AE?=
=?UTF-8?q?=20#9371=20#9627?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../rich-text/DeRichTextView.vue | 18 ++++++------------
1 file changed, 6 insertions(+), 12 deletions(-)
diff --git a/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue b/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue
index e505a5129b..67d82c5e40 100644
--- a/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue
+++ b/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue
@@ -223,21 +223,15 @@ const assignment = content => {
on.forEach(itm => {
if (dataRowFiledName.value.includes(itm)) {
const ele = itm.slice(1, -1)
- if (initReady.value) {
+ let value = dataRowNameSelect.value[ele] !== undefined ? dataRowNameSelect.value[ele] : null
+ if (value && thresholdStyleInfo && thresholdStyleInfo[ele]) {
const thresholdStyle = thresholdStyleInfo[ele]
- let value =
- dataRowNameSelect.value[ele] !== undefined ? dataRowNameSelect.value[ele] : null
- if (value && thresholdStyle) {
- value = `${value}`
- }
+ value = `${value}`
+ }
+ if (initReady.value) {
content = content.replace(itm, !!value ? value : '[未获取字段值]')
} else {
- content = content.replace(
- itm,
- dataRowNameSelect.value[ele] !== undefined
- ? dataRowNameSelect.value[ele]
- : '[获取中...]'
- )
+ content = content.replace(itm, !!value ? value : '[获取中...]')
}
}
})