Skip to content

Commit

Permalink
Fix fetching of taxonomy catDesc/term,
Browse files Browse the repository at this point in the history
  • Loading branch information
TomazErjavec committed Sep 12, 2023
1 parent ee4123f commit 252f83c
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions Scripts/parlamint-lib.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,7 @@
<xsl:if test="key('idr', ., $rootHeader)/
ancestor::tei:taxonomy/tei:desc/tei:term = 'Subcorpora'">
<!-- The category term of the tokenised @ana: -->
<xsl:value-of select="et:l10n($corpus-language,
key('idr', ., $rootHeader)//tei:catDesc)/tei:term"/>
<xsl:value-of select="et:l10n($corpus-language, key('idr', ., $rootHeader)/tei:catDesc)/tei:term"/>
<xsl:text>&#32;</xsl:text>
</xsl:if>
</xsl:for-each>
Expand Down Expand Up @@ -193,8 +192,8 @@
<xsl:variable name="bods">
<xsl:for-each select="distinct-values(tokenize(normalize-space($references), ' '))">
<xsl:if test="key('idr', ., $rootHeader)[ancestor::tei:category[@xml:id = 'parla.organization']]">
<xsl:variable name="body-en" select="et:l10n('en', key('idr', ., $rootHeader)//tei:catDesc)/tei:term"/>
<xsl:variable name="body" select="et:l10n($corpus-language, key('idr', ., $rootHeader)//tei:catDesc)/tei:term"/>
<xsl:variable name="body-en" select="et:l10n('en', key('idr', ., $rootHeader)/tei:catDesc)/tei:term"/>
<xsl:variable name="body" select="et:l10n($corpus-language, key('idr', ., $rootHeader)/tei:catDesc)/tei:term"/>
<!-- We unfortunatelly need an explicit test if the reference we got is appropriate -->
<!-- This needs to be rethought! (e.g. 'National Parliament' might be better than 'Unicameralism' -->
<xsl:if test="$body-en = 'Unicameralism' or
Expand Down Expand Up @@ -348,8 +347,7 @@
<xsl:for-each select="tokenize($ana, ' ')">
<xsl:if test="key('idr', ., $rootHeader)/
ancestor::tei:taxonomy/tei:desc/tei:term = 'Types of speakers'">
<xsl:value-of select="et:l10n($corpus-language,
key('idr', ., $rootHeader)//tei:catDesc)/tei:term"/>
<xsl:value-of select="et:l10n($corpus-language, key('idr', ., $rootHeader)/tei:catDesc)/tei:term"/>
</xsl:if>
</xsl:for-each>
</xsl:variable>
Expand Down

0 comments on commit 252f83c

Please sign in to comment.