From acf8d9719fe55260ee5ae2ccff3b1b4732bcbf72 Mon Sep 17 00:00:00 2001
From: RuoYi <yzz_ivy@163.com>
Date: Mon, 01 Nov 2021 15:45:10 +0800
Subject: [PATCH] 修复字符串无法被反转义问题
---
ruoyi-ui/src/utils/ruoyi.js | 15 +++++++++++++--
1 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/ruoyi-ui/src/utils/ruoyi.js b/ruoyi-ui/src/utils/ruoyi.js
index 1d867d4..0bdaa61 100644
--- a/ruoyi-ui/src/utils/ruoyi.js
+++ b/ruoyi-ui/src/utils/ruoyi.js
@@ -87,8 +87,8 @@
var temp = value.split(currentSeparator);
Object.keys(value.split(currentSeparator)).some((val) => {
Object.keys(datas).some((key) => {
- if (datas[key].dictValue == ('' + temp[val])) {
- actions.push(datas[key].dictLabel + currentSeparator);
+ if (datas[key].value == ('' + temp[val])) {
+ actions.push(datas[key].label + currentSeparator);
}
})
})
@@ -214,3 +214,14 @@
}
return result
}
+
+// 验证是否为blob格式
+export async function blobValidate(data) {
+ try {
+ const text = await data.text();
+ JSON.parse(text);
+ return false;
+ } catch (error) {
+ return true;
+ }
+}
--
Gitblit v1.9.3