浏览代码

请求大小

lyhzzz 2 年之前
父节点
当前提交
4f890a0d2f

+ 1 - 1
src/main/java/com/fdkankan/manage_jp/service/impl/CompanyServiceImpl.java

@@ -69,8 +69,8 @@ public class CompanyServiceImpl extends ServiceImpl<ICompanyMapper, Company> imp
         if(!ObjectUtils.isEmpty(userEntity)){
             throw new BusinessException(ResultCode.USER_EXIST);
         }
-        entity.setState(1);
         BeanUtils.copyProperties(param, entity);
+        entity.setState(1);
         entity.setAuditTime(new Date());
         this.save(entity);
 

+ 6 - 0
src/main/resources/bootstrap.yml

@@ -1,4 +1,10 @@
 spring:
+  servlet:
+    multipart:
+      #       设置单个文件大小
+      max-file-size: 20MB
+      #       设置单次请求文件的总大小
+      max-request-size: 50MB
   profiles:
     active: test
 logging: