|
@@ -378,7 +378,7 @@ public class RateService {
|
|
|
AtomicInteger num = new AtomicInteger(1);
|
|
AtomicInteger num = new AtomicInteger(1);
|
|
|
urls.forEach(privacy -> {
|
|
urls.forEach(privacy -> {
|
|
|
num.getAndIncrement();
|
|
num.getAndIncrement();
|
|
|
- if (getSuffix(privacy).equals("doc") || getSuffix(privacy).equals("docx")) {
|
|
|
|
|
|
|
+ if ("doc".equals(getSuffix(privacy)) || "docx".equals(getSuffix(privacy))) {
|
|
|
InputStream is1 = HttpRequest.get(privacy)
|
|
InputStream is1 = HttpRequest.get(privacy)
|
|
|
.stream();
|
|
.stream();
|
|
|
InputStream stream = HttpRequest.post("http://convert.izouma.com/word2pdf")
|
|
InputStream stream = HttpRequest.post("http://convert.izouma.com/word2pdf")
|
|
@@ -386,7 +386,7 @@ public class RateService {
|
|
|
.part("file", "审核材料.docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", is1)
|
|
.part("file", "审核材料.docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", is1)
|
|
|
.stream();
|
|
.stream();
|
|
|
files.add(stream);
|
|
files.add(stream);
|
|
|
- } else if (getSuffix(privacy).equals("pdf")) {
|
|
|
|
|
|
|
+ } else if ("pdf".equals(getSuffix(privacy))) {
|
|
|
InputStream stream = HttpRequest.get(privacy).stream();
|
|
InputStream stream = HttpRequest.get(privacy).stream();
|
|
|
files.add(stream);
|
|
files.add(stream);
|
|
|
}
|
|
}
|
|
@@ -406,12 +406,6 @@ public class RateService {
|
|
|
.receive(file);
|
|
.receive(file);
|
|
|
files.add(file);
|
|
files.add(file);
|
|
|
this.downloadFile(files, rate.getPrivacyPolicy(), "法人资格");
|
|
this.downloadFile(files, rate.getPrivacyPolicy(), "法人资格");
|
|
|
-// this.downloadFile(files, rate.getBusiness(), "业务内容");
|
|
|
|
|
-// this.downloadFile(files, rate.getCredits(), "社会信誉");
|
|
|
|
|
-// this.downloadFile(files, rate.getFire(), "消防安全");
|
|
|
|
|
-// this.downloadFile(files, rate.getHygiene(), "卫生防疫");
|
|
|
|
|
-// this.downloadFile(files, rate.getFinance(), "财务报表");
|
|
|
|
|
-// this.downloadFile(files, rate.getProperty(), "房产证明");
|
|
|
|
|
return files;
|
|
return files;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -420,14 +414,14 @@ public class RateService {
|
|
|
urls.forEach(privacy -> {
|
|
urls.forEach(privacy -> {
|
|
|
num.getAndIncrement();
|
|
num.getAndIncrement();
|
|
|
File file1 = new File("/Users/qiufangchao/Desktop/" + filename + num + ".pdf");
|
|
File file1 = new File("/Users/qiufangchao/Desktop/" + filename + num + ".pdf");
|
|
|
- if (getSuffix(privacy).equals("doc") || getSuffix(privacy).equals("docx")) {
|
|
|
|
|
|
|
+ if ("doc".equals(getSuffix(privacy)) || "docx".equals(getSuffix(privacy))) {
|
|
|
InputStream is1 = HttpRequest.get(privacy).stream();
|
|
InputStream is1 = HttpRequest.get(privacy).stream();
|
|
|
HttpRequest.post("http://convert.izouma.com/word2pdf")
|
|
HttpRequest.post("http://convert.izouma.com/word2pdf")
|
|
|
.accept("*/*")
|
|
.accept("*/*")
|
|
|
.part("file", "审核材料.docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", is1)
|
|
.part("file", "审核材料.docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", is1)
|
|
|
.receive(file1);
|
|
.receive(file1);
|
|
|
files.add(file1);
|
|
files.add(file1);
|
|
|
- } else if (getSuffix(privacy).equals("pdf")) {
|
|
|
|
|
|
|
+ } else if ("pdf".equals(getSuffix(privacy))) {
|
|
|
HttpRequest.get(privacy).receive(file1);
|
|
HttpRequest.get(privacy).receive(file1);
|
|
|
files.add(file1);
|
|
files.add(file1);
|
|
|
}
|
|
}
|