| | |
| | | description = description.replaceAll(s.getContent(), "***"); |
| | | } |
| | | } |
| | | language = userInfoService.queryLanguage(uid, language); |
| | | Complaint complaint = new Complaint(); |
| | | complaint.setInsertTime(new Date()); |
| | | complaint.setDriverId(driverId); |
| | |
| | | fileWriter.write(document.html()); |
| | | fileWriter.flush(); |
| | | fileWriter.close(); |
| | | FileInputStream fileInputStream = new FileInputStream(file); |
| | | File file1 = new File("/usr/local/nginx/html/files/pdf/"); |
| | | if(!file1.exists()){ |
| | | file1.mkdirs(); |
| | | } |
| | | file1 = new File("/usr/local/nginx/html/files/pdf/complain_" + randomString + ".pdf"); |
| | | if(!file1.exists()){ |
| | | file1.createNewFile(); |
| | | } |
| | | FileOutputStream fileOutputStream = new FileOutputStream(file1); |
| | | HtmlToPdfUtils.convertToPdf(fileInputStream, "IGO", fileOutputStream); |
| | | |
| | | String link ="http://182.160.16.251:81/files/html/complain_" + randomString + ".html"; |
| | | TEmail tEmail = new TEmail(); |