From 9fe11a3b1c7ca926e2f4e97e36c2911c290a0ab2 Mon Sep 17 00:00:00 2001
From: 董国庆 <364620639@qq.com>
Date: 星期一, 30 六月 2025 14:23:54 +0800
Subject: [PATCH] 修改bug

---
 laboratory/src/components/DynamicComponent/index.vue |   14 +++++++-------
 1 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/laboratory/src/components/DynamicComponent/index.vue b/laboratory/src/components/DynamicComponent/index.vue
index a093c13..99fa6a1 100644
--- a/laboratory/src/components/DynamicComponent/index.vue
+++ b/laboratory/src/components/DynamicComponent/index.vue
@@ -16,7 +16,7 @@
       <div v-for="(item, idx) in components" :key="item.id" class="dynamic-component">
         <!-- 富文本 -->
         <div v-if="item.type == 'richText'">
-          <AiEditor :ref="`editor_${item.id}`" :value="item.data.content" height="200px" :readOnly="!editable"
+          <AiEditor :ref="`editor_${item.id}`" :value="item.data.content" height="400px" :readOnly="!editable"
             placeholder="请输入内容..." :disabled="!editable" />
         </div>
         <!-- 自定义表格 -->
@@ -36,7 +36,7 @@
                 </template>
                 <!-- 图片类型显示 -->
                 <template v-else-if="header.type === 'image'">
-                  <img v-if="scope.row[header.name]" :src="getFullUrl(scope.row[header.name])" alt="头像"
+                  <el-image v-if="scope.row[header.name]" :preview-src-list="[getFullUrl(scope.row[header.name])]" :src="getFullUrl(scope.row[header.name])" alt="头像"
                     class="table-image" />
                 </template>
                 <!-- 其他类型 -->
@@ -487,16 +487,16 @@
     beforeImageUpload(file) {
       const isJPG = file.type === 'image/jpeg';
       const isPNG = file.type === 'image/png';
-      const isLt2M = file.size / 1024 / 1024 < 2;
+      // const isLt2M = file.size / 1024 / 1024 < 2;
 
       if (!isJPG && !isPNG) {
         this.$message.error('上传图片只能是 JPG 或 PNG 格式!');
         return false;
       }
-      if (!isLt2M) {
-        this.$message.error('上传图片大小不能超过 2MB!');
-        return false;
-      }
+      // if (!isLt2M) {
+      //   this.$message.error('上传图片大小不能超过 2MB!');
+      //   return false;
+      // }
       this.imagePreviewVisible = true;
       return true;
     },

--
Gitblit v1.7.1