@@ -71,7 +71,7 @@ export default {
if (file.size > this.maxSize) {
this.errorMsg =
- "文件大小不能超过" + Math.floor(this.maxSize / 1024) + "M";
+ "文件大小不能超过" + Math.floor(this.maxSize / (1024 * 1024)) + "M";
this.$emit("file-change", { errorMsg: this.errorMsg });
return;
}
@@ -112,7 +112,7 @@ export default {
},
handleExceededSize() {
const content =
this.res = {
success: false,
message: content,
@@ -183,7 +183,7 @@ export default {