podcast.xsl: refactor logic for pentamedia.xml
This commit is contained in:
parent
3ee96ee3af
commit
2135690f4e
|
@ -103,37 +103,32 @@
|
|||
<xsl:for-each select="newsfile">
|
||||
<xsl:sort select="date:seconds(document(.)/item/@date)" data-type="number" order="descending" />
|
||||
<xsl:choose>
|
||||
<xsl:when test="$selection = 'pentaradio' or $selection = 'pentamedia'">
|
||||
<xsl:if test="starts-with(., 'content/news/pentaradio') and
|
||||
<xsl:when test="($selection = 'pentaradio' or $selection = 'pentamedia') and
|
||||
starts-with(., 'content/news/pentaradio') and
|
||||
count(document(.)/item/resource) > 0">
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:when>
|
||||
<xsl:when test="$selection = 'pentacast' or $selection = 'pentamedia'">
|
||||
<xsl:if test="starts-with(., 'content/news/pentacast') and
|
||||
<xsl:when test="($selection = 'pentacast' or $selection = 'pentamedia') and
|
||||
starts-with(., 'content/news/pentacast') and
|
||||
count(document(.)/item/resource) > 0">
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:when>
|
||||
<xsl:when test="$selection = 'pentamusic' or $selection = 'pentamedia'">
|
||||
<xsl:if test="starts-with(., 'content/news/pentamusic') and
|
||||
<xsl:when test="($selection = 'pentamusic' or $selection = 'pentamedia') and
|
||||
starts-with(., 'content/news/pentamusic') and
|
||||
count(document(.)/item/resource) > 0">
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:when>
|
||||
<xsl:when test="$selection = '' and count(document(.)/item/resource) > 0">
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:if test="count(document(.)/item/resource) > 0">
|
||||
<xsl:apply-templates select="document(.)/item/resource" mode="preselect">
|
||||
<xsl:with-param name="newsfile" select="."/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:if>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:for-each>
|
||||
</channel>
|
||||
|
|
Loading…
Reference in New Issue