From df1a84d5ae1190946b54c57e17aab45a3647337a Mon Sep 17 00:00:00 2001 From: 疯狂的狮子Li <15040126243@163.com> Date: 星期五, 23 二月 2024 15:23:49 +0800 Subject: [PATCH] !86 bugfix: 修复文件预览大写后缀预览时效的问题 Merge pull request !86 from 北桥/dev --- src/components/ImageUpload/index.vue | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/components/ImageUpload/index.vue b/src/components/ImageUpload/index.vue index 47945dd..ae5cd45 100644 --- a/src/components/ImageUpload/index.vue +++ b/src/components/ImageUpload/index.vue @@ -46,7 +46,10 @@ import { globalHeaders } from '@/utils/request'; const props = defineProps({ - modelValue: [String, Object, Array], + modelValue: { + type: [String, Object, Array], + default: () => [] + }, // 鍥剧墖鏁伴噺闄愬埗 limit: propTypes.number.def(5), // 澶у皬闄愬埗(MB) @@ -78,14 +81,14 @@ watch( () => props.modelValue, - async (val) => { + async (val: string) => { if (val) { // 棣栧厛灏嗗�艰浆涓烘暟缁� let list: OssVO[] = []; if (Array.isArray(val)) { list = val as OssVO[]; } else { - const res = await listByIds(val as string); + const res = await listByIds(val); list = res.data; } // 鐒跺悗灏嗘暟缁勮浆涓哄璞℃暟缁� -- Gitblit v1.9.3