Bugzilla – Attachment 142290 Details for
Bug 15048
Genre/Form (655) searches fail on searches with $x 'General subdivision' subfield values
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15048: Index all possible searched subfields for index-term-genre
Bug-15048-Index-all-possible-searched-subfields-fo.patch (text/plain), 3.42 KB, created by
Marcel de Rooy
on 2022-10-21 06:33:07 UTC
(
hide
)
Description:
Bug 15048: Index all possible searched subfields for index-term-genre
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2022-10-21 06:33:07 UTC
Size:
3.42 KB
patch
obsolete
>From 8b13373f36fe7e3aee72d5e60206c92c2dbafc3f Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Thu, 23 Jun 2022 11:40:44 +0000 >Subject: [PATCH] Bug 15048: Index all possible searched subfields for > index-term-genre >Content-Type: text/plain; charset=utf-8 > >Currently we only index a - but we can setup the system such that avxyz are searched > >To test: > 1 - define both a 655$a *and* 655$x value in a bib, save, reindex > 2 - Set system preferences: > TraceSubjectSubdivisions: Include > TraceCompleteSubfields: Force > 3 - View the record edited above in the opac > 4 - Click on the subject heading > 5 - No results found > 6 - Copy zebra files: > sudo cp ./etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml \ > /etc/koha/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml > sudo cp etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl \ > /etc/koha/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl > 7 - restart all and reindex > 8 - Click on the subject heading in OPAC > 9 - Sucess! >10 - Repeat with other fields (vyz) >11 - Repeat under ES, reindexing and resetting mappings > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > admin/searchengine/elasticsearch/mappings.yaml | 2 +- > etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml | 2 +- > etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl | 2 +- > 3 files changed, 3 insertions(+), 3 deletions(-) > >diff --git a/admin/searchengine/elasticsearch/mappings.yaml b/admin/searchengine/elasticsearch/mappings.yaml >index 33f36852eb..435e5339e7 100644 >--- a/admin/searchengine/elasticsearch/mappings.yaml >+++ b/admin/searchengine/elasticsearch/mappings.yaml >@@ -1679,7 +1679,7 @@ biblios: > label: index-term-genre > mappings: > - facet: '' >- marc_field: 655a >+ marc_field: 655avxyz > marc_type: marc21 > sort: ~ > suggestible: '' >diff --git a/etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml b/etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml >index 7b1895968b..9d660b7fd6 100644 >--- a/etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml >+++ b/etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml >@@ -789,7 +789,7 @@ > <target_index>Subject:p</target_index> > </index_data_field> > <!--melm 655$a Index-term-genre --> >- <index_subfields tag="655" subfields="a"> >+ <index_subfields tag="655" subfields="axvyz"> > <target_index>Index-term-genre:w</target_index> > <target_index>Index-term-genre:p</target_index> > <target_index>Subject:w</target_index> >diff --git a/etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl b/etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl >index b3222fadb5..c5a0fed4b4 100644 >--- a/etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl >+++ b/etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl >@@ -722,7 +722,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) > </xslo:template> > <xslo:template mode="index_subfields" match="marc:datafield[@tag='655']"> > <xslo:for-each select="marc:subfield"> >- <xslo:if test="contains('a', @code)"> >+ <xslo:if test="contains('axvyz', @code)"> > <z:index name="Index-term-genre:w Index-term-genre:p Subject:w Subject:p"> > <xslo:value-of select="."/> > </z:index> >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 15048
:
43794
|
43795
|
44040
|
44041
|
48887
|
136449
|
137842
| 142290