lyhzzz недель назад: 2
Родитель
Сommit
5b59bc601a

+ 0 - 3
src/main/java/com/fdkankan/fusion/service/impl/ModelServiceImpl.java

@@ -79,9 +79,6 @@ public class ModelServiceImpl extends ServiceImpl<IModelMapper, Model> implement
         if(file.isEmpty()){
             throw new BusinessException(ResultCode.UPLOAD_FILE_NO_EXIST);
         }
-        if(file.getSize()>10 * 1024 * 1024 * 100){
-            throw new BusinessException(ResultCode.UPLOAD_FILE_TO_LONG);
-        }
         //获取文件名
         String fileName = file.getOriginalFilename();
         if(StringUtils.isEmpty(fileName)){

+ 0 - 7
src/main/java/com/fdkankan/fusion/service/impl/UploadService.java

@@ -35,10 +35,6 @@ public class UploadService {
         if(file.isEmpty()){
             throw new BusinessException(ResultCode.UPLOAD_FILE_NO_EXIST);
         }
-        if(file.getSize()>10 * 1024 * 1024 * 100){
-            System.out.println(file.getSize());
-            throw new BusinessException(ResultCode.UPLOAD_FILE_TO_LONG);
-        }
         //获取文件名
         String fileName = file.getOriginalFilename();
         if(StringUtils.isEmpty(fileName)){
@@ -70,9 +66,6 @@ public class UploadService {
         if(file.isEmpty()){
             throw new BusinessException(ResultCode.UPLOAD_FILE_NO_EXIST);
         }
-        if(file.getSize()>10 * 1024 * 1024 * 100){
-            throw new BusinessException(ResultCode.UPLOAD_FILE_TO_LONG);
-        }
         //获取文件名
         String fileName = file.getOriginalFilename();
         if(StringUtils.isEmpty(fileName)){