Как вывести все товары выбранного раздела каталога вне зависимости от вложенности XSLT — различия между версиями
Материал из Umicms
Строка 1: | Строка 1: | ||
<source lang="xml"> | <source lang="xml"> | ||
− | + | <xsl:template match="/result[@method = 'category'][count(/result/parents/page) = 1]"> | |
− | + | <xsl:apply-templates select="document(concat('udata://catalog/getObjectsList/', page/@id, '////2/'))/udata" /> | |
− | + | </xsl:template> | |
− | + | <xsl:template match="/result[@method = 'category'][count(/result/parents/page) = 2]"> | |
− | + | <xsl:apply-templates select="document('udata://catalog/getObjectsList/notemplate/342///5/')" /> | |
− | + | </xsl:template> | |
− | + | ||
− | + | <xsl:template match="/result[@method = 'category'][count(/result/parents/page) = 3]"> | |
− | + | <xsl:apply-templates select="document('udata://catalog/search/{@id}///72')" /> | |
− | + | <xsl:apply-templates select="document('udata://catalog/getObjectsList/notemplate/10//////')" /> | |
− | + | </xsl:template> | |
</source> | </source> |
Версия 10:46, 7 июня 2013
<xsl:template match="/result[@method = 'category'][count(/result/parents/page) = 1]">
<xsl:apply-templates select="document(concat('udata://catalog/getObjectsList/', page/@id, '////2/'))/udata" />
</xsl:template>
<xsl:template match="/result[@method = 'category'][count(/result/parents/page) = 2]">
<xsl:apply-templates select="document('udata://catalog/getObjectsList/notemplate/342///5/')" />
</xsl:template>
<xsl:template match="/result[@method = 'category'][count(/result/parents/page) = 3]">
<xsl:apply-templates select="document('udata://catalog/search/{@id}///72')" />
<xsl:apply-templates select="document('udata://catalog/getObjectsList/notemplate/10//////')" />
</xsl:template>