版本管理限制上传exe文件

This commit is contained in:
2024-09-05 13:41:52 +08:00
parent b8a08eea4f
commit fe90fd7fc2

View File

@@ -56,11 +56,11 @@ export default {
},
methods: {
beforeUpload(file) {
// const isExe = file.name.endsWith(".exe");
// if (!isExe) {
// this.$message.error("只允许上传.exe文件");
// return false; // 阻止上传
// }
const isExe = file.name.endsWith(".exe");
if (!isExe) {
this.$message.error("只允许上传.exe文件");
return false; // 阻止上传
}
return true; // 允许上传
},
uploadVersionFile(e) {