|
3528 | 3528 | <!-- <xsl:call-template name="insertIndexInSeparatePageSequences"/> -->
|
3529 | 3529 | </xsl:template> <!-- END: insertMainSectionsInSeparatePageSequences -->
|
3530 | 3530 |
|
3531 |
| - <xsl:template name="insertAnnexAndBibliographyInSeparatePageSequences"> |
| 3531 | + <xsl:template name="insertAnnexAndBibliographyInSeparatePageSequences"> |
3532 | 3532 | <xsl:for-each select="/*/*[local-name()='annex'] | /*/*[local-name()='bibliography']/*[not(@normative='true')] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]] | /*/*[local-name()='indexsect']">
|
3533 | 3533 | <xsl:sort select="@displayorder" data-type="number"/>
|
3534 | 3534 | <xsl:choose>
|
@@ -12357,10 +12357,12 @@
|
12357 | 12357 | <xsl:template match="*[local-name() = 'metanorma-extension']/*[local-name() = 'attachment']" mode="update_xml_step1">
|
12358 | 12358 | <xsl:copy>
|
12359 | 12359 | <xsl:copy-of select="@*"/>
|
12360 |
| - <xsl:variable name="name_filepath" select="concat($inputxml_basepath, @name)"/> |
12361 |
| - <xsl:variable name="file_exists" select="normalize-space(java:exists(java:java.io.File.new($name_filepath)))"/> |
12362 |
| - <xsl:if test="$file_exists = 'false'"> <!-- copy attachment content only if file on disk doesnt exist --> |
12363 |
| - <xsl:value-of select="."/> |
| 12360 | + <xsl:if test="1 = 2"> <!-- remove attachment/text(), because attachments added in the template 'addPDFUAmeta' before applying 'update_xml_step1' --> |
| 12361 | + <xsl:variable name="name_filepath" select="concat($inputxml_basepath, @name)"/> |
| 12362 | + <xsl:variable name="file_exists" select="normalize-space(java:exists(java:java.io.File.new($name_filepath)))"/> |
| 12363 | + <xsl:if test="$file_exists = 'false'"> <!-- copy attachment content only if file on disk doesnt exist --> |
| 12364 | + <xsl:value-of select="normalize-space(.)"/> |
| 12365 | + </xsl:if> |
12364 | 12366 | </xsl:if>
|
12365 | 12367 | </xsl:copy>
|
12366 | 12368 | </xsl:template>
|
|
13342 | 13344 | <xsl:for-each select="//*[contains(local-name(), '-standard')]/*[local-name() = 'metanorma-extension']/*[local-name() = 'attachment']">
|
13343 | 13345 | <xsl:choose>
|
13344 | 13346 | <xsl:when test="normalize-space() != ''">
|
13345 |
| - <pdf:embedded-file src="{.}" filename="{@name}"/> |
| 13347 | + <xsl:variable name="src_attachment" select="java:replaceAll(java:java.lang.String.new(.),'( | | )', '')"/> <!-- remove line breaks --> |
| 13348 | + <pdf:embedded-file src="{$src_attachment}" filename="{@name}"/> |
13346 | 13349 | </xsl:when>
|
13347 | 13350 | <xsl:otherwise>
|
13348 | 13351 | <!-- _{filename}_attachments -->
|
|
0 commit comments