From f2a587c2f98b245bcc1d2a73ed5203394b7bacd5 Mon Sep 17 00:00:00 2001
From: RuoYi <yzz_ivy@163.com>
Date: Mon, 18 Mar 2024 14:30:11 +0800
Subject: [PATCH] 更新compressionPlugin到6.1.2以兼容node18+
---
ruoyi-ui/src/components/ImagePreview/index.vue | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/ruoyi-ui/src/components/ImagePreview/index.vue b/ruoyi-ui/src/components/ImagePreview/index.vue
index 14a245b..2fa02d7 100644
--- a/ruoyi-ui/src/components/ImagePreview/index.vue
+++ b/ruoyi-ui/src/components/ImagePreview/index.vue
@@ -17,7 +17,7 @@
props: {
src: {
type: String,
- required: true
+ default: ""
},
width: {
type: [Number, String],
@@ -30,10 +30,16 @@
},
computed: {
realSrc() {
+ if (!this.src) {
+ return;
+ }
let real_src = this.src.split(",")[0];
return real_src;
},
realSrcList() {
+ if (!this.src) {
+ return;
+ }
let real_src_list = this.src.split(",");
let srcList = [];
real_src_list.forEach(item => {
--
Gitblit v1.9.3