Bug 23053: Add phrase index to authority Local-Number
authorNick Clemens <nick@bywatersolutions.com>
Wed, 5 Jun 2019 13:55:10 +0000 (13:55 +0000)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Tue, 11 Jun 2019 07:37:40 +0000 (08:37 +0100)
To test:
 1 - Define a matching rule for authorities on field 001 index Local-Number
 2 - In koha-conf.xml raise the zebra_loglevels
     <zebra_loglevels>none,fatal,warn,request,info</zebra_loglevels>
 3 - Export some authorities using the tools->export data
 4 - Import those authorities
 5 - Note no matches found
 6 - View the zebra output log, you should see lots of error 114
 7 - Apply patch
 8 - Copy the indexdefs files to the installed versions
 9 - Reapply matchign rules to staged files
10 - Matches should now be found
11 - Logs should not have errors

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
etc/zebradb/marc_defs/marc21/authorities/authority-koha-indexdefs.xml
etc/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl

index 52652bc..39b4602 100644 (file)
@@ -24,6 +24,7 @@ authority-zebra-indexdefs.xsl`
   <!-- Original record ID -->
   <kohaidx:index_control_field tag="001">
     <kohaidx:target_index>Local-Number:w</kohaidx:target_index>
+    <kohaidx:target_index>Local-Number:p</kohaidx:target_index>
     <kohaidx:target_index>Local-Number:n</kohaidx:target_index>
     <kohaidx:target_index>Local-Number:s</kohaidx:target_index>
   </kohaidx:index_control_field>
index b4bf51d..a6e472c 100644 (file)
@@ -53,7 +53,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml)
     </z:index>
   </xslo:template>
   <xslo:template match="marc:controlfield[@tag='001']">
-    <z:index name="Local-Number:w Local-Number:n Local-Number:s">
+    <z:index name="Local-Number:w Local-Number:n Local-Number:s Local-Number:p">
       <xslo:value-of select="."/>
     </z:index>
   </xslo:template>