From 4ac2063039244bb45edfa4de2fac3ea02a5c9d77 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Tue, 27 Jan 2026 20:08:08 +0000 Subject: [PATCH] Bug 41210: Adjust ES and Zebra mappings This fixes the issue for ES. For zebra I cannot get the search to work - I believe I added the fields and updated correctly but putting this on the bug for testiing: For SearchEngine Elasticsearch 1 - Apply patch 2 - perl misc/search_tools/rebuild_elasticsearch.pl -r -v 3 - Add sample record as stated in bug 4 - Confirm all links work For SearchEngine Zebra 1 - Apply patch 2 - sudo cp /kohadevbox/koha/etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl /etc/koha/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl 3 - restart_all 4 - sudo koha-rebuild-zebra -v -f kohadev 5 - Confirm all links in record work 6 - They don't currently --- .../searchengine/elasticsearch/mappings.yaml | 12 ++-- .../marc21/biblios/biblio-koha-indexdefs.xml | 40 +++++++++---- .../marc21/biblios/biblio-zebra-indexdefs.xsl | 60 ++++++++++++++++--- 3 files changed, 86 insertions(+), 26 deletions(-) diff --git a/admin/searchengine/elasticsearch/mappings.yaml b/admin/searchengine/elasticsearch/mappings.yaml index 6f69baf4834..e7561cf574f 100644 --- a/admin/searchengine/elasticsearch/mappings.yaml +++ b/admin/searchengine/elasticsearch/mappings.yaml @@ -1051,17 +1051,17 @@ biblios: mandatory: ~ mappings: - facet: 1 - marc_field: 100a + marc_field: 100abcjq(abcjq) marc_type: marc21 sort: 1 suggestible: 1 - facet: 1 - marc_field: 110a + marc_field: 110ab(ab) marc_type: marc21 sort: 1 suggestible: 1 - facet: 1 - marc_field: 111a + marc_field: 111aeq(aeq) marc_type: marc21 sort: 1 suggestible: 1 @@ -1071,17 +1071,17 @@ biblios: sort: 1 suggestible: '' - facet: 1 - marc_field: 700a + marc_field: 700abcjq(abcjq) marc_type: marc21 sort: 1 suggestible: 1 - facet: 1 - marc_field: 710a + marc_field: 710ab(ab) marc_type: marc21 sort: 1 suggestible: 1 - facet: 1 - marc_field: 711a + marc_field: 711aeq(aeq) marc_type: marc21 sort: 1 suggestible: 1 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 e2ab9205ca0..bdec18593de 100644 --- a/etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml +++ b/etc/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml @@ -269,7 +269,7 @@ Koha-Auth-Number:w - + Author:w Author:p Author:s @@ -280,9 +280,6 @@ - Author:w - Author:p - Author:s Author-title:w Author-name-personal:w Name:w @@ -294,6 +291,17 @@ Koha-Auth-Number:w + + Author:w + Author:p + Author:s + Author-title:w + Author-name-corporate:w + Name:w + Name-and-title:w + Corporate-name:w + Corporate-name:p + Author:w Author:p @@ -310,10 +318,12 @@ Koha-Auth-Number:w - + Author:w Author:p Author:s + + Author-title:w Author-name-corporate:w Name:w @@ -880,10 +890,11 @@ Cross-Reference:w Koha-Auth-Number:w - - + + Author:w Author:p + Author:s @@ -902,8 +913,6 @@ - Author:w - Author:p Author-name-personal:w Name:w Editor:w @@ -917,7 +926,7 @@ Title-uniform:w - + Name-and-title:w @@ -925,13 +934,18 @@ Koha-Auth-Number:w - + Author:w Author:p Corporate-name:w Corporate-name:p Name:w + + Corporate-name:w + Corporate-name:p + Name:w + Name-and-title:w @@ -947,9 +961,11 @@ Koha-Auth-Number:w - + Author:w Author:p + + Author-name-corporate:w Name:w Conference-name:w 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 c540d485f3a..9ef776a1636 100644 --- a/etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl +++ b/etc/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl @@ -254,7 +254,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - + @@ -849,8 +849,8 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - - + + @@ -886,7 +886,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - + @@ -1912,7 +1912,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - + @@ -1936,9 +1936,31 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + - + + + + + + + + + + + + @@ -2445,7 +2467,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - + @@ -2469,9 +2491,31 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + - + + + + + + + + + + + + -- 2.39.5