[Koha] Creating additional indexes and adding to the facet

Serdar Gokhan beytobeyto1974 at gmail.com
Thu Feb 11 22:32:39 NZDT 2016


Hi,

I use the following procedures from
https://wiki.koha-community.org/wiki/How_to_add_new_zebra_index and
https://wiki.koha-community.org/wiki/Understanding_Zebra_indexing, but get
no facet shown:


/etc/koha/zebradb/marc_defs/marc21/biblios/biblio-koha-indexdefs.xml:
 <index_data_field xmlns="http://www.koha-community.org/schemas/index-defs"
tag="380" subfields="a">
     <target_index>FormOfWork:w</target_index>
 </index_data_field>

/etc/koha/zebradb/biblios/etc/bib1.att:
 att 10000    FormOfWork

/etc/koha/zebradb/ccl.properties:
 FormOfWork 1=10000

lib/C4/Koha.pm, in sub getFacets, (non-unimarc):
{
                idx   => 'FormOfWork',
                label => 'FormOfWork',
                tags  => [ qw/ 380a / ],
                sep   => '--',
 },

opac/htdocs/opac-tmpl/bootstrap/<LANG>/includes/opac-facets.inc, after  [%
FOREACH facets_loo IN facets_loop %]:
  [% IF facets_loo.type_label_FormOfWork %]<h5 id="facet-FormOfWork">Form
of work</h5>[% END %]

lib/C4/Search.pm, in sub getIndexesn my @indexes added:
 'FormOfWork',

Running:
xsltproc /etc/koha/zebradb/xsl/koha-indexdefs-to-zebra.xsl
/etc/koha/zebradb/marc_defs/marc21/biblios/    biblio-koha-indexdefs.xml
>/etc/koha/zebradb/marc_defs/marc21/biblios/biblio-zebra-indexdefs.xsl
koha-rebuild-zebra -b -f -v library
koha-restart-zebra

Example MARC21 record:
 380$a Play

What am I doing wrong?

Thanks,

Dit e-mailbericht is verzonden vanaf een virusvrije computer die wordt
beschermd door Avast.
www.avast.com <https://www.avast.com/sig-email>
<#DDB4FAA8-2DD7-40BB-A1B8-4E2AA1F9FDF2>


More information about the Koha mailing list