【修改】文件上传限制

This commit is contained in:
zhoulingpo
2023-05-16 16:54:43 +08:00
parent f59e56f009
commit a376fce78f
@@ -467,7 +467,7 @@ export default {
beforeUploadFile(file) {
let realFileType = file.name.split('.')[file.name.split('.').length - 1];
const isType = (
file.type === fileType.pdf || file.type === fileType.xls || file.type === fileType.xlsx || file.type === fileType.doc || file.type === fileType.docx || file.type === fileType.ppt || file.type === fileType.pptx
file.type === fileType.pdf || file.type === fileType.ppt || file.type === fileType.pptx
|| realFileType === 'pdf' || realFileType === 'ppt' || realFileType === 'pptx'
);
const isSize = file.size / 1024 / 1024 < 200;