View | Details | Raw Unified | Return to bug 36982
Collapse All | Expand All

(-)a/Koha/SearchEngine/Elasticsearch/Search.pm (-1 / +2 lines)
Lines 451-460 sub _convert_facets { Link Here
451
    my @libraries = Koha::Libraries->search->as_list;
451
    my @libraries = Koha::Libraries->search->as_list;
452
    my $library_names = { map { $_->branchcode => $_->branchname } @libraries };
452
    my $library_names = { map { $_->branchcode => $_->branchname } @libraries };
453
    my @locations = Koha::AuthorisedValues->search( { category => 'LOC' } )->as_list;
453
    my @locations = Koha::AuthorisedValues->search( { category => 'LOC' } )->as_list;
454
    my @collections = Koha::AuthorisedValues->search( { category => 'CCODE' } )->as_list;
454
    my $opac = C4::Context->interface eq 'opac' ;
455
    my $opac = C4::Context->interface eq 'opac' ;
455
    my %special = (
456
    my %special = (
456
        itype    => { map { $_->itemtype         => $_->description } @itypes },
457
        itype    => { map { $_->itemtype         => $_->description } @itypes },
457
        location => { map { $_->authorised_value => ( $opac ? ( $_->lib_opac || $_->lib ) : $_->lib ) } @locations },
458
        location => { map { $_->authorised_value => ( $opac ? ( $_->lib_opac || $_->lib ) : $_->lib ) } @locations },
459
        ccode => { map { $_->authorised_value => ( $opac ? ( $_->lib_opac || $_->lib ) : $_->lib ) } @collections },
458
        holdingbranch => $library_names,
460
        holdingbranch => $library_names,
459
        homebranch => $library_names
461
        homebranch => $library_names
460
    );
462
    );
461
- 

Return to bug 36982