From 28e0afedeff400887a161cec76bd8881600b62c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B0=A2=E6=80=9D?= <2897217417@qq.com> Date: Tue, 29 Nov 2022 16:46:33 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E5=BA=93=E4=B8=8A=E4=BC=A0?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E9=99=90=E5=88=B6=E6=96=87=E4=BB=B6=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/forge/Upload/read.js | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/forge/Upload/read.js b/src/forge/Upload/read.js index 9e5a09863..921374120 100644 --- a/src/forge/Upload/read.js +++ b/src/forge/Upload/read.js @@ -49,6 +49,10 @@ class Read extends Component { "psd", "cdr", "webp", + "vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "vnd.ms-powerpoint", + "vnd.openxmlformats-officedocument.presentationml.presentation", + "vnd.ms-excel" ]; const { fileList } = this.state; const { size } = this.props; @@ -59,7 +63,7 @@ class Read extends Component { } else if (!isLt100M) { this.props.showNotification(`文件大小必须小于${size}MB!`); } else if (file_type && forbidden_type.indexOf(file_type) !== -1) { - this.props.showNotification(`不支持${file_type}类型`); + this.props.showNotification(`仅支持文本格式,不支持图片,excel等不可以txt读取的文件`); } else { this.setState({ fileList: [file], @@ -91,9 +95,9 @@ class Read extends Component {

拖动文件或点击此处上传

- {/*

- 暂仅支持文件格式,不支持图片,excel等不可以txt读取的文件 -

*/} +

+ 暂仅支持文本格式,不支持图片,excel等不可以txt读取的文件 +

文件名请使用英文且不得超过{size}MB