|
3464 | 3464 | <!-- <xsl:call-template name="insertIndexInSeparatePageSequences"/> -->
|
3465 | 3465 | </xsl:template> <!-- END: insertMainSectionsInSeparatePageSequences -->
|
3466 | 3466 |
|
3467 |
| - <xsl:template name="insertAnnexAndBibliographyInSeparatePageSequences"> |
| 3467 | + <xsl:template name="insertAnnexAndBibliographyInSeparatePageSequences"> |
3468 | 3468 | <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']">
|
3469 | 3469 | <xsl:sort select="@displayorder" data-type="number"/>
|
3470 | 3470 | <xsl:choose>
|
@@ -12312,10 +12312,12 @@
|
12312 | 12312 | <xsl:template match="*[local-name() = 'metanorma-extension']/*[local-name() = 'attachment']" mode="update_xml_step1">
|
12313 | 12313 | <xsl:copy>
|
12314 | 12314 | <xsl:copy-of select="@*"/>
|
12315 |
| - <xsl:variable name="name_filepath" select="concat($inputxml_basepath, @name)"/> |
12316 |
| - <xsl:variable name="file_exists" select="normalize-space(java:exists(java:java.io.File.new($name_filepath)))"/> |
12317 |
| - <xsl:if test="$file_exists = 'false'"> <!-- copy attachment content only if file on disk doesnt exist --> |
12318 |
| - <xsl:value-of select="."/> |
| 12315 | + <xsl:if test="1 = 2"> <!-- remove attachment/text(), because attachments added in the template 'addPDFUAmeta' before applying 'update_xml_step1' --> |
| 12316 | + <xsl:variable name="name_filepath" select="concat($inputxml_basepath, @name)"/> |
| 12317 | + <xsl:variable name="file_exists" select="normalize-space(java:exists(java:java.io.File.new($name_filepath)))"/> |
| 12318 | + <xsl:if test="$file_exists = 'false'"> <!-- copy attachment content only if file on disk doesnt exist --> |
| 12319 | + <xsl:value-of select="normalize-space(.)"/> |
| 12320 | + </xsl:if> |
12319 | 12321 | </xsl:if>
|
12320 | 12322 | </xsl:copy>
|
12321 | 12323 | </xsl:template>
|
|
13297 | 13299 | <xsl:for-each select="//*[contains(local-name(), '-standard')]/*[local-name() = 'metanorma-extension']/*[local-name() = 'attachment']">
|
13298 | 13300 | <xsl:choose>
|
13299 | 13301 | <xsl:when test="normalize-space() != ''">
|
13300 |
| - <pdf:embedded-file src="{.}" filename="{@name}"/> |
| 13302 | + <xsl:variable name="src_attachment" select="java:replaceAll(java:java.lang.String.new(.),'( | | )', '')"/> <!-- remove line breaks --> |
| 13303 | + <pdf:embedded-file src="{$src_attachment}" filename="{@name}"/> |
13301 | 13304 | </xsl:when>
|
13302 | 13305 | <xsl:otherwise>
|
13303 | 13306 | <!-- _{filename}_attachments -->
|
|
0 commit comments