分控材料 文件名相同 导致打成zip包失败

master
dalong306 4 years ago
parent 541a74da48
commit 2eb1818500

@ -578,7 +578,7 @@ public class RiskBusinessServiceImpl implements RiskBusinessService, ManagerTodo
if (riskMaterial.containsKey("file" + i)) {
List<String> fileList = (List<String>) riskMaterial.get("file" + i);
for (String fileUrl : fileList) {
zos.putNextEntry(new ZipEntry("file" + i + fileUrl.substring(fileUrl.lastIndexOf("/"))));
zos.putNextEntry(new ZipEntry("file" + i +"/"+System.currentTimeMillis()+"_"+fileUrl.substring(fileUrl.lastIndexOf("/")+1)));
InputStream inputStream = new URL(fileUrl).openConnection().getInputStream();
byte[] buffer = new byte[1024];
int result = 0;

Loading…
Cancel
Save