From e212a0ab75e1c59d0d030ac0b2f07048f6a0f9cf Mon Sep 17 00:00:00 2001 From: RuoYi <yzz_ivy@163.com> Date: 星期三, 04 十二月 2024 20:32:06 +0800 Subject: [PATCH] 支持开启暗黑模式 --- src/components/FileUpload/index.vue | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletions(-) diff --git a/src/components/FileUpload/index.vue b/src/components/FileUpload/index.vue index ad67460..0d19c5e 100644 --- a/src/components/FileUpload/index.vue +++ b/src/components/FileUpload/index.vue @@ -104,10 +104,15 @@ const fileExt = fileName[fileName.length - 1]; const isTypeOk = props.fileType.indexOf(fileExt) >= 0; if (!isTypeOk) { - proxy.$modal.msgError(`鏂囦欢鏍煎紡涓嶆纭�, 璇蜂笂浼�${props.fileType.join("/")}鏍煎紡鏂囦欢!`); + proxy.$modal.msgError(`鏂囦欢鏍煎紡涓嶆纭紝璇蜂笂浼�${props.fileType.join("/")}鏍煎紡鏂囦欢!`); return false; } } + // 鏍℃鏂囦欢鍚嶆槸鍚﹀寘鍚壒娈婂瓧绗� + if (file.name.includes(',')) { + proxy.$modal.msgError('鏂囦欢鍚嶄笉姝g‘锛屼笉鑳藉寘鍚嫳鏂囬�楀彿!'); + return false; + } // 鏍℃鏂囦欢澶у皬 if (props.fileSize) { const isLt = file.size / 1024 / 1024 < props.fileSize; -- Gitblit v1.9.3