|
@@ -114,13 +114,20 @@ public class TSupervisePcsjServiceImpl implements ITSupervisePcsjService {
|
|
|
String d0_filepath = d0.getFilepath();
|
|
|
int d1_unzip_len = d0_unzippath.lastIndexOf("/");
|
|
|
int d1_filepath = d0_filepath.lastIndexOf("/");
|
|
|
- String d2_unzippath = d0_unzippath.substring(0, d1_unzip_len) + "/REMOVE" + d0_unzippath.substring(d1_unzip_len);
|
|
|
- String d2_filepath = d0_filepath.substring(0, d1_filepath) + "/REMOVE" + d0_filepath.substring(d1_filepath);
|
|
|
+ String uuid = StringUtils.getUUID();
|
|
|
+ String d2_unzippath = d0_unzippath.substring(0, d1_unzip_len) + "/REMOVE/" + uuid + d0_unzippath.substring(d1_unzip_len);
|
|
|
+ String d2_filepath = d0_filepath.substring(0, d1_filepath) + "/REMOVE/" + uuid + d0_filepath.substring(d1_filepath);
|
|
|
|
|
|
try {
|
|
|
+ if (new File(d0_unzippath.substring(0, d1_unzip_len) + "/REMOVE/" + uuid).exists()) {
|
|
|
+ Files.createDirectories(Paths.get(d0_unzippath.substring(0, d1_unzip_len) + "/REMOVE/" + uuid));
|
|
|
+ }
|
|
|
if (new File(d0_unzippath).exists()) {
|
|
|
Files.move(Paths.get(d0_unzippath), Paths.get(d2_unzippath));
|
|
|
}
|
|
|
+ if (new File(d0_filepath.substring(0, d1_filepath) + "/REMOVE/" + uuid).exists()) {
|
|
|
+ Files.createDirectories(Paths.get(d0_filepath.substring(0, d1_filepath) + "/REMOVE/" + uuid));
|
|
|
+ }
|
|
|
if (new File(d0_filepath).exists()) {
|
|
|
Files.move(Paths.get(d0_filepath), Paths.get(d2_filepath));
|
|
|
}
|