-
Notifications
You must be signed in to change notification settings - Fork 2
/
browseIndexToResultPage.xslt
45 lines (31 loc) · 1.2 KB
/
browseIndexToResultPage.xslt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:zs="http://www.loc.gov/zing/srw/"
xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<!-- This xslt stylesheet generates the resultPage
from a Solr browseIndex.
-->
<xsl:output method="xml" indent="yes" encoding="UTF-8"/>
<xsl:param name="STARTTERM" select="query"/>
<xsl:param name="TERMPAGESIZE" select="10"/>
<xsl:param name="RESULTPAGEXSLT" select="resultPageXslt"/>
<xsl:param name="DATETIME" select="none"/>
<xsl:template match="solrbrowseindex">
<xsl:variable name="INDEXNAME" select="@indexName"/>
<xsl:variable name="FIELDNAME" select="@fieldName"/>
<xsl:variable name="TERMTOTAL" select="@termTotal"/>
<resultPage dateTime="{$DATETIME}"
indexName="{$INDEXNAME}">
<browseIndex startTerm="{$STARTTERM}"
fieldName="{$FIELDNAME}"
termPageSize="{$TERMPAGESIZE}"
resultPageXslt="{$RESULTPAGEXSLT}"
termTotal="{$TERMTOTAL}">
<xsl:copy-of select="fields"/>
<xsl:copy-of select="terms"/>
</browseIndex>
</resultPage>
</xsl:template>
</xsl:stylesheet>