Commit 8994ccb5 by chenweisong

更新

parent 34eb1435
...@@ -5,6 +5,7 @@ import org.springframework.context.annotation.Bean; ...@@ -5,6 +5,7 @@ import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
import javax.servlet.MultipartConfigElement; import javax.servlet.MultipartConfigElement;
import java.io.File;
@Configuration @Configuration
public class AppConfig { public class AppConfig {
...@@ -16,7 +17,12 @@ public class AppConfig { ...@@ -16,7 +17,12 @@ public class AppConfig {
@Bean @Bean
MultipartConfigElement multipartConfigElement() { MultipartConfigElement multipartConfigElement() {
MultipartConfigFactory factory = new MultipartConfigFactory(); MultipartConfigFactory factory = new MultipartConfigFactory();
factory.setLocation("./temp"); String location = System.getProperty("user.dir") + "/data/tmp";
File tmpFile = new File(location);
if (!tmpFile.exists()) {
tmpFile.mkdirs();
}
factory.setLocation(location);
return factory.createMultipartConfig(); return factory.createMultipartConfig();
} }
} }
...@@ -53,8 +53,6 @@ spring: ...@@ -53,8 +53,6 @@ spring:
activiti: activiti:
check-process-definitions: false # 关闭验证自动部署 check-process-definitions: false # 关闭验证自动部署
server: server:
tomcat:
basedir: ./temp
port: 8110 port: 8110
app: app:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment