From fe252a8cfb2228d36413aaddf006fdcbf9045cf1 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Thu, 4 Sep 2014 13:11:07 -0300 Subject: [PATCH] Bug 11232: Add new syntax for facets definition on koha-indexdefs-to-zebra.xsl This patch changes koha-indexdefs-to-zebra.xsl to correctly process a new syntax for defining facet indexes on the XML files. It also changes the retrieval file to allow access to Zebra's internal data from Zoom (i.e. access to zebra::facet:*). Sponsored-by: Universidad Nacional de Cordoba Signed-off-by: David Cook Seems to work with DOM and MARC21. --- debian/templates/marc21-retrieval-info-bib-dom.xml | 2 + .../templates/normarc-retrieval-info-bib-dom.xml | 2 + .../templates/unimarc-retrieval-info-bib-dom.xml | 2 + etc/zebradb/retrieval-info-bib-dom.xml | 7 ++ etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl | 100 +++++++++++++++++++- 5 files changed, 108 insertions(+), 5 deletions(-) diff --git a/debian/templates/marc21-retrieval-info-bib-dom.xml b/debian/templates/marc21-retrieval-info-bib-dom.xml index 7e45f38..c7ce0ac 100644 --- a/debian/templates/marc21-retrieval-info-bib-dom.xml +++ b/debian/templates/marc21-retrieval-info-bib-dom.xml @@ -14,9 +14,11 @@ outputcharset="utf-8"/> + + diff --git a/debian/templates/normarc-retrieval-info-bib-dom.xml b/debian/templates/normarc-retrieval-info-bib-dom.xml index f723f9a..9d62631 100644 --- a/debian/templates/normarc-retrieval-info-bib-dom.xml +++ b/debian/templates/normarc-retrieval-info-bib-dom.xml @@ -14,9 +14,11 @@ outputcharset="utf-8"/> + + diff --git a/debian/templates/unimarc-retrieval-info-bib-dom.xml b/debian/templates/unimarc-retrieval-info-bib-dom.xml index 941f8e8..7699dc5 100644 --- a/debian/templates/unimarc-retrieval-info-bib-dom.xml +++ b/debian/templates/unimarc-retrieval-info-bib-dom.xml @@ -14,9 +14,11 @@ outputcharset="utf-8"/> + + diff --git a/etc/zebradb/retrieval-info-bib-dom.xml b/etc/zebradb/retrieval-info-bib-dom.xml index c966937..4fe781d 100644 --- a/etc/zebradb/retrieval-info-bib-dom.xml +++ b/etc/zebradb/retrieval-info-bib-dom.xml @@ -15,4 +15,11 @@ + + + + + diff --git a/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl b/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl index 1488b1c..03e635f 100644 --- a/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl +++ b/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl @@ -12,10 +12,11 @@ - - - - + + + + + @@ -33,6 +34,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + @@ -57,6 +59,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + @@ -69,6 +72,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + @@ -104,7 +108,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - + @@ -288,6 +292,38 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + marc:datafield[@tag=' + + '] + + + + not(@ind1='z') + + + + + + + + + + + + + + + + + + + + + @@ -475,4 +511,58 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + marc:subfield[@code=' + + '] + + + + + + + + + + + + + + + + marc:subfield[@code=' + + '] and marc:subfield[@code=' + + '] + + <*> + + + + marc:subfield[@code=' + + '] + + + + + + + + + -- 1.7.7.4