private void fillPdfTemplateData(File file, Map<String, String> params, String targetFileUrl) throws IOException {
PdfDocument pdf = new PdfDocument(new PdfReader(file), new PdfWriter(targetFileUrl));
PdfAcroForm form = PdfAcroForm.getAcroForm(pdf, true);//第二个参数,如果不显示值设置为true
Map<String, PdfFormField> fields = form.getFormFields();
String path = this.getClass().getResource("/").getPath();
path = path.substring(0, path.indexOf("classes") - 1) + "/classes/font/simsun.ttc,1";
//使用指定字体如--微软雅黑
PdfFont font = PdfFontFactory.createFont(path, PdfEncodings.IDENTITY_H, BaseFont.EMBEDDED);
//PdfFont font = PdfFontFactory.createFont("STSongStd-Light", "UniGB-UCS2-H", false);
//遍历值域,填充对应值
Iterator<String> it = fields.keySet().iterator();
while (it.has