|
@@ -62,7 +62,6 @@
|
|
import { useI18n } from '/@/hooks/web/useI18n';
|
|
import { useI18n } from '/@/hooks/web/useI18n';
|
|
import type { UploadProps } from 'ant-design-vue';
|
|
import type { UploadProps } from 'ant-design-vue';
|
|
import { debounce } from 'lodash-es';
|
|
import { debounce } from 'lodash-es';
|
|
-
|
|
|
|
const { t } = useI18n();
|
|
const { t } = useI18n();
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
components: { BasicModal, BasicForm, Upload },
|
|
components: { BasicModal, BasicForm, Upload },
|
|
@@ -210,13 +209,13 @@
|
|
if (!isExcel) {
|
|
if (!isExcel) {
|
|
createMessage.error('支持jpg、png、jpeg、mp4、wav、mp3 、shp、zip格式文件上传');
|
|
createMessage.error('支持jpg、png、jpeg、mp4、wav、mp3 、shp、zip格式文件上传');
|
|
fileList.value = [];
|
|
fileList.value = [];
|
|
- return false;
|
|
|
|
|
|
+ return Upload.LIST_IGNORE;
|
|
}
|
|
}
|
|
const isLt10M = file.size / 1024 / 1024 < 2000;
|
|
const isLt10M = file.size / 1024 / 1024 < 2000;
|
|
if (!isLt10M) {
|
|
if (!isLt10M) {
|
|
fileList.value = [];
|
|
fileList.value = [];
|
|
createMessage.error('上传文件不能超过 2G!');
|
|
createMessage.error('上传文件不能超过 2G!');
|
|
- return false;
|
|
|
|
|
|
+ return Upload.LIST_IGNORE;
|
|
}
|
|
}
|
|
fileList.value = [file];
|
|
fileList.value = [file];
|
|
return false;
|
|
return false;
|