publish 0.0.9

This commit is contained in:
曾文豪
2023-01-10 11:40:43 +08:00
parent abd5c2456b
commit 9e0d2ac571
19 changed files with 120 additions and 50 deletions

View File

@@ -6,7 +6,7 @@
<parent>
<groupId>com.tiesheng</groupId>
<artifactId>tiesheng-parent</artifactId>
<version>0.0.8</version>
<version>0.0.9</version>
</parent>
<artifactId>tiesheng-util</artifactId>

View File

@@ -37,6 +37,7 @@ public class FileUploadPath {
}
pathBean.setHttpPath(tempPath);
pathBean.setAbsolutePath(String.format("%s/static%s", System.getProperty("user.dir"), tempPath));
FileUtil.mkParentDirs(pathBean.getAbsolutePath());
return pathBean;
}
@@ -52,6 +53,16 @@ public class FileUploadPath {
}
/**
* 随机生成一个文件路径
*
* @return
*/
public static FileUploadPath random(String fileExt) {
return get(IdUtil.simpleUUID() + "." + fileExt);
}
/**
* 获取一个目录
*