From 4ffaa07a40a9cb6648779ed8aa0984827e87f7b2 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Mon, 6 May 2024 11:38:44 +0200 Subject: [PATCH] Bug 36750: Use the same label for Zebra Signed-off-by: Nick Clemens Signed-off-by: Katrin Fischer --- C4/Koha.pm | 14 +++++++------- .../intranet-tmpl/prog/en/includes/facets.inc | 6 +++--- .../bootstrap/en/includes/opac-facets.inc | 4 ++-- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/C4/Koha.pm b/C4/Koha.pm index 41b6003de4..1c3e2ceb2d 100644 --- a/C4/Koha.pm +++ b/C4/Koha.pm @@ -347,7 +347,7 @@ sub getFacets { }, { idx => 'ccode', - label => 'CollectionCodes', + label => 'Collections', tags => [ qw / 099t 955h / ], } ]; @@ -362,7 +362,7 @@ sub getFacets { @$facets, { idx => 'holdingbranch', - label => 'HoldingLibrary', + label => 'Holding libraries', tags => [qw / 995c /], } ); @@ -375,7 +375,7 @@ sub getFacets { @$facets, { idx => 'homebranch', - label => 'HomeLibrary', + label => 'Home libraries', tags => [qw / 995b /], } ); @@ -422,7 +422,7 @@ sub getFacets { }, { idx => 'itype', - label => 'ItemTypes', + label => 'Item types', tags => [ qw/ 952y 942c / ], sep => ', ', }, @@ -433,7 +433,7 @@ sub getFacets { }, { idx => 'ccode', - label => 'CollectionCodes', + label => 'Collections', tags => [ qw / 9528 / ], } ]; @@ -448,7 +448,7 @@ sub getFacets { @$facets, { idx => 'holdingbranch', - label => 'HoldingLibrary', + label => 'Holding libraries', tags => [qw / 952b /], } ); @@ -461,7 +461,7 @@ sub getFacets { @$facets, { idx => 'homebranch', - label => 'HomeLibrary', + label => 'Home libraries', tags => [qw / 952a /], } ); diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/facets.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/facets.inc index 2834691541..82262f6c25 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/facets.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/facets.inc @@ -85,9 +85,9 @@ [% url = BLOCK %][% url | $raw %][% "&count=" _ results_per_page | url %][% END %] [% END %] [% FOREACH facet IN facets_loo.facets %] - [% IF facets_loo.type_label_CollectionCodes %] + [% IF facets_loo.label == 'Collections' %] [% SET facet.facet_label_value = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.ccode', authorised_value => facet.facet_label_value ) || facet.facet_label_value %] - [% ELSIF facets_loo.type_label_Language %] + [% IF facets_loo.label == 'Languages' %] [% SET facet.facet_label_value = Languages.GetByISOCode(lang,facet.facet_label_value) || facet.facet_label_value %] [% END %] [% IF loop.count > 5 && !facet.active %] @@ -95,7 +95,7 @@ [% ELSE %]
  • [% END %] - [% SET facet_is_current_library = ( facets_loo.type_label_HomeLibrary || facets_loo.type_label_HoldingLibrary ) && !singleBranchMode && facet.facet_title_value == Branches.GetLoggedInBranchcode %] + [% SET facet_is_current_library = ( facets_loo.label == 'Home libraries' || facets_loo.label == 'Holding libraries' ) && !singleBranchMode && facet.facet_title_value == Branches.GetLoggedInBranchcode %] [% SET facet_label_class = facet_is_current_library ? 'facet-label currentlibrary' : 'facet-label' %] [% IF facet.active %] [% local_url = BLOCK %][% url | $raw %][% "&nolimit=" _ facet.type_link_value _ ":" _ facet.facet_link_value | url %][% END %] diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-facets.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-facets.inc index 04e4a3c05a..c3c89b6fa2 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-facets.inc +++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-facets.inc @@ -89,8 +89,8 @@ [% url = BLOCK %][% url | $raw %][% "&count=" _ results_per_page | url %][% END %] [% END %] [% FOREACH facet IN facets_loo.facets %] - [% IF facets_loo.type_label_CollectionCodes %][% SET facet.facet_label_value = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.ccode', authorised_value => facet.facet_label_value, opac =>1 ) || facet.facet_label_value %][% END %] - [% IF facets_loo.type_label_Language %][% SET facet.facet_label_value = Languages.GetByISOCode(lang,facet.facet_label_value) || facet.facet_label_value %][% END %] + [% IF facets_loo.label == 'Collections' %][% SET facet.facet_label_value = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.ccode', authorised_value => facet.facet_label_value, opac =>1 ) || facet.facet_label_value %][% END %] + [% IF facets_loo.label == 'Language' %][% SET facet.facet_label_value = Languages.GetByISOCode(lang,facet.facet_label_value) || facet.facet_label_value %][% END %] [% IF loop.count > 5 && !facet.active %]