Commit 7c3be153 authored by Dennis Neumann's avatar Dennis Neumann
Browse files

Fix bugs

parent 7a18f9e2
......@@ -197,7 +197,7 @@ Furthermore, a warning message is generated that contains data of the first occu
<xsl:text> </xsl:text>
</xsl:template>
<xsl:template match="note[@place='end']" mode="text_only">
<xsl:template match="note[@place='end' and not(@type='com')]" mode="text_only">
<xsl:text> </xsl:text>
<xsl:apply-templates mode="text_only" />
</xsl:template>
......@@ -246,7 +246,7 @@ Furthermore, a warning message is generated that contains data of the first occu
<doc>
<xsl:variable name="pageNumber" select="count(self::pb/preceding::pb) + 1" />
<field name="id">
<xsl:value-of select="$context/../../@xml:id" />
<xsl:value-of select="$context/@xml:id" />
<xsl:text>_page</xsl:text>
<xsl:value-of select="$pageNumber" />
</field>
......
......@@ -50,6 +50,7 @@ public class XsltSplitTest {
xslt.transform("src/test/resources/tei-snippets-split/" + "two-page-beginnings.xml", outputBaos);
String xml = outputBaos.toString();
assertXpathEvaluatesTo("2", "//field[@name='number_of_pages']", xml);
assertXpathEvaluatesTo("my_id_page1", "//doc[2]/field[@name='id']", xml);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment