Browse Source

获取远程链接的地址的base64

aQiu6 3 months ago
parent
commit
fd3d58b833

+ 4 - 5
src/main/java/org/example/mybatisplus/Controller/IndexController.java

@@ -48,12 +48,11 @@ public class IndexController {
                 "测试"
         ));
         // 将图片转换为 Base64 编码
-        String imageBase64 = DocxGenerator.convertImageToBase64("G:\\Code\\new\\fxy-tool\\src\\main\\resources\\pic1.png");
+//        String imageBase64 = DocxGenerator.convertImageToBase64("G:\\Code\\new\\fxy-tool\\src\\main\\resources\\pic1.png");
         Attachment attach = new Attachment();
-        attach.setFileName("关联实体情况.png");
-
-        attach.setBase64(imageBase64);
+        attach.setFilePath("https://yyc3-1321096020.cos.ap-beijing.myqcloud.com/declaration/20250313/dc8220a3a722486d9ccd632972a3ab15.png?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20250317T075010Z&X-Amz-SignedHeaders=host&X-Amz-Expires=86399&X-Amz-Credential=AKIDRilauFg4fDfE9B6tJoNxTvHSdovqXBfw%2F20250317%2Fap-beijing%2Fs3%2Faws4_request&X-Amz-Signature=e2b1cbe340254b2b63c97ffadeee183b52409f5fa77384e68ed7298b501f8666");
         List<Attachment> attachments= Arrays.asList(attach);
+
         basicInfo.setRelatedEntitiesImage(attachments);
         PublicRecord publicRecord=new PublicRecord();
         DishonestPerson person=new DishonestPerson();
@@ -63,7 +62,7 @@ public class IndexController {
         person.setExecutionSubject("nsubiec有");
         person.setFilingDate("2000-25-22");
         person.setId(2);
-        person.setIsHistorical("tori的");
+        person.setIsHistorical(true);
         List<DishonestPerson> persons=new ArrayList<>();
         persons.add(person);
         publicRecord.setDishonestPersons(persons);

+ 61 - 2
src/main/java/org/example/mybatisplus/module/vo/Attachment.java

@@ -1,16 +1,75 @@
 package org.example.mybatisplus.module.vo;
 
 import lombok.Data;
+import org.example.mybatisplus.tools.ImageUtils;
+
+import java.util.List;
 
 /**
  * 附件对象
  */
-@Data
 public class Attachment {
     private String fileName;
     private String filePath;
     private String fileType;//附件类型,图片或pdf
     private String width;
     private String height;//图片显示高度
-    private String base64;//图片base64
+    private List<String> base64;//图片base64
+    public String getFileName() {
+        return fileName;
+    }
+
+    public void setFileName(String fileName) {
+        this.fileName = fileName;
+    }
+
+    public String getFilePath() {
+        return filePath;
+    }
+
+    public void setFilePath(String filePath) {
+        this.filePath = filePath;
+        this.fileName = filePath.substring(filePath.lastIndexOf("/") + 1,filePath.lastIndexOf("."));
+        this.base64 = ImageUtils.urlTobase64(filePath);
+    }
+
+    public String getImg() {
+        return img;
+    }
+
+    public void setImg(String img) {
+        this.img = img;
+    }
+
+    public String getFileType() {
+        return fileType;
+    }
+
+    public void setFileType(String fileType) {
+        this.fileType = fileType;
+    }
+
+    public String getWidth() {
+        return width;
+    }
+
+    public void setWidth(String width) {
+        this.width = width;
+    }
+
+    public String getHeight() {
+        return height;
+    }
+
+    public void setHeight(String height) {
+        this.height = height;
+    }
+
+    public List<String> getBase64() {
+        return base64;
+    }
+
+    public void setBase64(List<String> base64) {
+        this.base64 = base64;
+    }
 }

+ 1 - 1
src/main/java/org/example/mybatisplus/module/vo/BusinessAbnormal.java

@@ -8,5 +8,5 @@ public class BusinessAbnormal {
     private String inclusionDate;        // 列入日期
     private String decisionAuthority;       // 作出决定机关(列入)
     private String reason;                  // 列入经营异常名录原因
-    private String isHistorical;           // 是否是历史记录
+    private Boolean isHistorical;           // 是否是历史记录
 }

+ 1 - 1
src/main/java/org/example/mybatisplus/module/vo/DishonestPerson.java

@@ -11,6 +11,6 @@ public class DishonestPerson {
     private String executionSubject;        // 执行标的(原文为“执行标地”,修正为Subject)
     private String dishonestBehavior;       // 失信被执行人具体情形
     private String executingCourt;          // 执行法院
-    private String isHistorical;           // 是否是历史记录(true/false)
+    private Boolean isHistorical;           // 是否是历史记录(true/false)
     private String performanceStatus;//被执行人履行情况
 }

+ 1 - 1
src/main/java/org/example/mybatisplus/module/vo/SevereViolation.java

@@ -11,6 +11,6 @@ public class SevereViolation {
     private String inclusionDate;        // 列入日期
     private String decisionAuthority;       // 作出决定机关(列入)
     private String reason;                  // 列入严重违法失信企业名单原因
-    private String isHistorical;           // 是否是历史记录
+    private Boolean isHistorical;           // 是否是历史记录
 
 }

+ 75 - 74
src/main/java/org/example/mybatisplus/tools/ImageUtils.java

@@ -1,6 +1,7 @@
 package org.example.mybatisplus.tools;
 
 
+import com.alibaba.fastjson2.JSON;
 import org.apache.pdfbox.pdmodel.PDDocument;
 import org.apache.pdfbox.rendering.PDFRenderer;
 import org.apache.poi.ss.usermodel.*;
@@ -9,6 +10,7 @@ import org.apache.poi.xwpf.usermodel.Document;
 import org.apache.poi.xwpf.usermodel.XWPFDocument;
 import org.apache.poi.xwpf.usermodel.XWPFParagraph;
 import org.apache.poi.xwpf.usermodel.XWPFRun;
+import org.example.mybatisplus.module.vo.Attachment;
 import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTPageMar;
 import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTPageSz;
 import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTSectPr;
@@ -18,21 +20,45 @@ import java.awt.Color;
 import java.awt.*;
 import java.awt.image.BufferedImage;
 import java.io.*;
+import java.net.URL;
 import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Base64;
 import java.util.List;
 
 public class ImageUtils {
-    public static List<BufferedImage> convertPdfToImages(String pdfPath, int dpi) throws Exception {
-        PDDocument document = PDDocument.load(new File(pdfPath));
+    public static List<String> convertPdfToImages(String pdfUrl) throws Exception {
+        URL url = new URL(pdfUrl);
+        InputStream is = url.openStream();
+        PDDocument document = PDDocument.load(is);
         PDFRenderer renderer = new PDFRenderer(document);
-        List<BufferedImage> images = new ArrayList<>();
+        List<String> images = new ArrayList<>();
         for (int i = 0; i < document.getNumberOfPages(); i++) {
-            BufferedImage image = renderer.renderImageWithDPI(i, dpi);
-            images.add(image);
+            BufferedImage image = renderer.renderImageWithDPI(i, 150);
+            images.add(bufferedImageToBase64(image));
         }
         document.close();
         return images;
     }
+
+    /**
+     * BufferedImage转base64
+     *
+     * @param bufferedImage
+     * @return
+     */
+    public static String bufferedImageToBase64(BufferedImage bufferedImage) {
+        ByteArrayOutputStream stream = new ByteArrayOutputStream();
+        try {
+            // 设置图片格式
+            ImageIO.write(bufferedImage, "jpg", stream);
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+        byte[] bytes = Base64.getEncoder().encode(stream.toByteArray());
+        String base64 = new String(bytes);
+        return base64;
+    }
     public static BufferedImage convertSheetToImage(Sheet sheet) {
         // 计算表格尺寸
         int rows = sheet.getPhysicalNumberOfRows();
@@ -60,79 +86,54 @@ public class ImageUtils {
         g.dispose();
         return image;
     }
-    public static void main(String[] args) throws Exception {
-        InputStream in = new FileInputStream("G:\\Code\\new\\fxy-tool\\input.docx");
-        // 创建新文档
-        XWPFDocument document = new XWPFDocument(in);
-        // 插入PDF图片
-//        List<BufferedImage> pdfImages = PdfToImage.convertPdfToImages("input.pdf", 150);
-//        for (BufferedImage img : pdfImages) {
-//            insertImage(doc, img, "PDF_Page");
-//        }
-
-        // 插入Excel图片
-        Workbook workbook = WorkbookFactory.create(new File("G:\\Code\\new\\fxy-tool\\input.xls"));
-        for (Sheet sheet : workbook) {
-            BufferedImage excelImage = convertSheetToImage(sheet);
-            insertImage1(document, excelImage, "Excel_Sheet");
+    public static String imgUrlToBase64(String imageUrl) {
+        try {
+            URL url = new URL(imageUrl);
+            InputStream is = url.openStream();
+            byte[] bytes = is.readAllBytes(); // 从流中读取所有字节
+            is.close();
+            return Base64.getEncoder().encodeToString(bytes);
+        } catch (Exception e) {
+            e.printStackTrace();
+            return null;
         }
-        workbook.close();
-
-        // 创建段落和运行对象
-        /*XWPFParagraph paragraph = document.createParagraph();
-        XWPFRun run = paragraph.createRun();
-        PDDocument pdf = PDDocument.load(new File("G:\\Code\\new\\fxy-tool\\1.pdf"));
-        PDFRenderer renderer = new PDFRenderer(pdf);
-        for (int i = 0; i < pdf.getNumberOfPages(); i++) {
-            BufferedImage image = renderer.renderImageWithDPI(i, 300);
-            // 读取图片文件到字节数组
-            InputStream is = bufferedImageToInputStream(image,"jpg");
-            ByteArrayOutputStream baos = new ByteArrayOutputStream();
-            byte[] buffer = new byte[4096];
-            int bytesRead;
-            while ((bytesRead = is.read(buffer)) != -1) {
-                baos.write(buffer, 0, bytesRead);
+    }
+    public static String getFileExtension(String path) {
+        if (path != null && path.contains(".")) {
+            String ext= path.substring(path.lastIndexOf(".") + 1);
+            if(ext.indexOf("?")>0){
+                ext = ext.substring(0,ext.indexOf("?"));
             }
-            byte[] imageBytes = baos.toByteArray();
-
-            // 获取图片原始尺寸
-            int originalWidth = image.getWidth();
-            int originalHeight = image.getHeight();
-
-            // 获取页面设置
-            CTSectPr sectPr = document.getDocument().getBody().getSectPr();
-            if (sectPr == null) {
-                sectPr = document.getDocument().getBody().addNewSectPr();
+            return ext.toLowerCase();
+        }
+        return "";
+    }
+    public static List<String> urlTobase64(String url) {
+        // 常见的图片文件扩展名列表
+        try {
+            List<String> imageExtensions = Arrays.asList("jpg", "jpeg", "png", "gif", "bmp", "tiff", "svg");
+            String ext= getFileExtension(url);
+            if(imageExtensions.contains(ext)){
+                List<String> list = new ArrayList<>();
+                list.add(imgUrlToBase64(url));
+                return list;
+            }else if(ext.equals("pdf")){
+                return convertPdfToImages(url);
             }
-
-            // 获取页面宽度和边距(单位为Twips)
-            CTPageSz pageSize = sectPr.getPgSz();
-            CTPageMar pageMar = sectPr.getPgMar();
-
-            long pageWidthTwips = Long.parseLong(pageSize.getW().toString());
-            long leftMarginTwips = Long.parseLong(pageMar.getLeft().toString());
-            long rightMarginTwips = Long.parseLong(pageMar.getRight().toString());
-
-            // 计算可用宽度(Twips)并转换为EMU
-            long availableWidthTwips = pageWidthTwips - leftMarginTwips - rightMarginTwips;
-            int targetWidthEMU = (int) (availableWidthTwips * Units.EMU_PER_DXA);
-
-            // 计算目标高度(保持宽高比)
-            int targetHeightEMU = (int) (targetWidthEMU * ((double) originalHeight / originalWidth));
-
-            // 插入图片
-            run.addPicture(new ByteArrayInputStream(imageBytes),
-                    Document.PICTURE_TYPE_JPEG,
-                    "pdf"+i+".png",
-                    targetWidthEMU,
-                    targetHeightEMU);
+        } catch (Exception e) {
+            throw new RuntimeException(e);
         }
-        pdf.close();*/
-        // 保存文档
-        FileOutputStream out = new FileOutputStream("output.docx");
-        document.write(out);
-        out.close();
-        document.close();
+
+        return null;
+    }
+    public static void main(String[] args) throws Exception {
+        String pdfUrl = "http://wap.xiuqiuengineering.com/jijinhui1.pdf"; // 替换为你的图片URL
+        String imageUrl = "https://yyc3-1321096020.cos.ap-beijing.myqcloud.com/declaration/20250313/dc8220a3a722486d9ccd632972a3ab15.png?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20250317T075010Z&X-Amz-SignedHeaders=host&X-Amz-Expires=86399&X-Amz-Credential=AKIDRilauFg4fDfE9B6tJoNxTvHSdovqXBfw%2F20250317%2Fap-beijing%2Fs3%2Faws4_request&X-Amz-Signature=e2b1cbe340254b2b63c97ffadeee183b52409f5fa77384e68ed7298b501f8666"; // 替换为你的图片URL
+        Attachment attach = new Attachment();
+        attach.setFileName("关联实体情况.png");
+        attach.setFilePath(imageUrl);
+        //List<String> base64Image = convertPdfToImages(imageUrl);
+        System.out.println(attach.getBase64().get(0));
     }
     public static InputStream bufferedImageToInputStream(BufferedImage bufferedImage, String format) throws IOException {
         // 创建一个ByteArrayOutputStream来存储图像数据

+ 1 - 1
src/main/java/org/example/mybatisplus/tools/WordToPdfUtil.java

@@ -47,7 +47,7 @@ public class WordToPdfUtil {
             doc.updateFields();//更新目录
             doc.save(wordPath, SaveFormat.DOCX);
             // 将Word文档保存为PDF格式,写入到之前创建的PDF文件中。
-            doc.save(os, SaveFormat.DOCX);
+            doc.save(os, SaveFormat.PDF);
         } catch (Exception e) {
             e.printStackTrace();
         } finally {

+ 115 - 107
src/main/resources/foundation_template.xml

@@ -14761,15 +14761,16 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                         <w:lang w:fareast="ZH-CN"/>
                     </w:rPr>
                     <w:t><#if basicInfo.relatedEntitiesImage??>
-       <#list basicInfo.relatedEntitiesImage as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+       <#list basicInfo.relatedEntitiesImage as item><#if item.base64??>
+       <#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
         <v:fill on="f" focussize="0,0"/>
         <v:stroke on="f"/>
         <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
         <o:lock v:ext="edit" aspectratio="t"/>
         <w10:wrap type="none"/>
-        <w10:anchorlock/></v:shape></w:pict></#list>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -16787,7 +16788,7 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                                     <w:sz-cs w:val="18"/>
                                     <w:lang w:val="EN-US" w:fareast="ZH-CN"/>
                                 </w:rPr>
-                                <w:t>${item.isHistorical}</w:t>
+                                <w:t> <#if item.isHistorical?? && item.isHistorical>是<#else>否</#if></w:t>
                             </w:r>
                         </w:p>
                     </w:tc>
@@ -17318,7 +17319,7 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                                     <w:sz w:val="18"/>
                                     <w:lang w:val="ZH-CN"/>
                                 </w:rPr>
-                                <w:t>${item.isHistorical!''}</w:t>
+                                <w:t> <#if item.isHistorical?? && item.isHistorical>是<#else>否</#if></w:t>
                             </w:r>
                         </w:p>
                     </w:tc>
@@ -18955,7 +18956,7 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                                     <w:sz w:val="18"/>
                                     <w:lang w:val="ZH-CN"/>
                                 </w:rPr>
-                                <w:t>${item.isHistorical!''}</w:t>
+                                <w:t> <#if item.isHistorical?? && item.isHistorical>是<#else>否</#if></w:t>
                             </w:r>
                         </w:p>
                     </w:tc>
@@ -28034,14 +28035,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t><#if projectInfo?? && projectInfo.files?? && projectInfo.files?size gt 0>
         <#list projectInfo.files as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
         <v:fill on="f" focussize="0,0"/>
         <v:stroke on="f"/>
         <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
         <o:lock v:ext="edit" aspectratio="t"/>
         <w10:wrap type="none"/>
-        <w10:anchorlock/></v:shape></w:pict></#list>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -28602,14 +28604,7 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t><#if interestConflict?? && interestConflict?size gt 0>
         <#list interestConflict as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-        <v:fill on="f" focussize="0,0"/>
-        <v:stroke on="f"/>
-        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-        <o:lock v:ext="edit" aspectratio="t"/>
-        <w10:wrap type="none"/>
-        <w10:anchorlock/></v:shape></w:pict></#list>
+        </#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -28868,14 +28863,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.foundationLegalPersonRegistrationCertificate?? && documentVo.foundationLegalPersonRegistrationCertificate?size gt 0>
         <#list documentVo.foundationLegalPersonRegistrationCertificate as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
         <v:fill on="f" focussize="0,0"/>
         <v:stroke on="f"/>
         <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
         <o:lock v:ext="edit" aspectratio="t"/>
         <w10:wrap type="none"/>
-        <w10:anchorlock/></v:shape></w:pict></#list>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -28924,14 +28920,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.foundationLegalPersonRegistrationCertificateLatest?? && documentVo.foundationLegalPersonRegistrationCertificateLatest?size gt 0>
         <#list documentVo.foundationLegalPersonRegistrationCertificateLatest as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
         <v:fill on="f" focussize="0,0"/>
         <v:stroke on="f"/>
         <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
         <o:lock v:ext="edit" aspectratio="t"/>
         <w10:wrap type="none"/>
-        <w10:anchorlock/></v:shape></w:pict></#list>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -28967,14 +28964,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.foundationLegalPersonRegistrationCertificateLatest?? && documentVo.bankAccountCertificateOrCreditCertificate?size gt 0>
         <#list documentVo.bankAccountCertificateOrCreditCertificate as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
         <v:fill on="f" focussize="0,0"/>
         <v:stroke on="f"/>
         <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
         <o:lock v:ext="edit" aspectratio="t"/>
         <w10:wrap type="none"/>
-        <w10:anchorlock/></v:shape></w:pict></#list>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29024,14 +29022,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.evaluationLevelQualificationCertificate?? && documentVo.evaluationLevelQualificationCertificate?size gt 0>
         <#list documentVo.evaluationLevelQualificationCertificate as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29085,14 +29084,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.completeArticlesOfAssociationCopy?? && documentVo.completeArticlesOfAssociationCopy?size gt 0>
         <#list documentVo.completeArticlesOfAssociationCopy as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29134,14 +29134,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.topTenDonorList?? && documentVo.topTenDonorList?size gt 0>
         <#list documentVo.topTenDonorList as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29177,14 +29178,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.topTenSpenderList?? && documentVo.topTenSpenderList?size gt 0>
         <#list documentVo.topTenSpenderList as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29231,14 +29233,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t><#if documentVo.organizationManagement?? && documentVo.organizationManagement?size gt 0>
         <#list documentVo.organizationManagement as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29334,14 +29337,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.relatedEntitySituation?? && documentVo.relatedEntitySituation?size gt 0>
         <#list documentVo.relatedEntitySituation as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29376,14 +29380,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.organizationPrincipal?? && documentVo.organizationPrincipal?size gt 0>
         <#list documentVo.organizationPrincipal as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29419,14 +29424,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.projectInformation?? && documentVo.projectInformation?size gt 0>
         <#list documentVo.projectInformation as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>
@@ -29462,14 +29468,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.organizationalStructureScan?? && documentVo.organizationalStructureScan?size gt 0>
         <#list documentVo.organizationalStructureScan as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if> </w:t>
                 </w:r>
             </w:p>
@@ -29530,14 +29537,15 @@ fmppOBQAc+lHWiiqAMnvSDk5FLRQFwoxRRQFz//Z
                     </w:rPr>
                     <w:t> <#if documentVo.overallGuaranteeStatement?? && documentVo.overallGuaranteeStatement?size gt 0>
         <#list documentVo.overallGuaranteeStatement as item>
-        <w:pict><w:binData w:name="wordml://${item.fileName!''}">${item.base64!''}</w:binData><v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;"
-                                                                                               filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
-            <v:fill on="f" focussize="0,0"/>
-            <v:stroke on="f"/>
-            <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
-            <o:lock v:ext="edit" aspectratio="t"/>
-            <w10:wrap type="none"/>
-            <w10:anchorlock/></v:shape></w:pict></#list>
+        <#if item.base64??><#list item.base64 as img>
+        <w:pict><w:binData w:name="wordml://{img_index}${item.fileName!''}">${img!''}</w:binData>
+        <v:shape id="_x0000_s1032" o:spt="75" alt="" type="#_x0000_t75" style="height:645.3pt;width:456.5pt;" filled="f" o:preferrelative="t" stroked="f" coordsize="21600,21600"><v:path/>
+        <v:fill on="f" focussize="0,0"/>
+        <v:stroke on="f"/>
+        <v:imagedata src="wordml://${item.fileName!''}" o:title="wordml://${item.fileName!''}"/>
+        <o:lock v:ext="edit" aspectratio="t"/>
+        <w10:wrap type="none"/>
+        <w10:anchorlock/></v:shape></w:pict></#list></#if></#list>
 </#if></w:t>
                 </w:r>
             </w:p>