二期:文件大小改为500M
This commit is contained in:
parent
528e7876a9
commit
a55a662ce9
|
@ -118,7 +118,7 @@ export default {
|
|||
file.callback(res)
|
||||
},
|
||||
beforeUpload(file) {
|
||||
const MAX_SIZE = 100 * 1024 * 1024 // 2MB
|
||||
const MAX_SIZE = 500 * 1024 * 1024 // 2MB
|
||||
if (file.size > MAX_SIZE) {
|
||||
this.$message.error('文件大小不能超过 100MB!')
|
||||
return false
|
||||
|
|
|
@ -17,7 +17,7 @@ const uploaderStore = defineStore('uploader', {
|
|||
pushFile(payload) {
|
||||
let _this = this
|
||||
let arr = payload.filter((item) => {
|
||||
const MAX_SIZE = 100 * 1024 * 1024; // 2MB
|
||||
const MAX_SIZE = 500 * 1024 * 1024; // 2MB
|
||||
if (item.size > MAX_SIZE) {
|
||||
ElMessage.error('文件大小不能超过 100MB!');
|
||||
return false;
|
||||
|
|
Loading…
Reference in New Issue