Lines 408-423
sub _convert_facets {
Link Here
|
408 |
'su-geo' => { order => 4, label => 'Places', }, |
408 |
'su-geo' => { order => 4, label => 'Places', }, |
409 |
se => { order => 5, label => 'Series', }, |
409 |
se => { order => 5, label => 'Series', }, |
410 |
subject => { order => 6, label => 'Topics', }, |
410 |
subject => { order => 6, label => 'Topics', }, |
|
|
411 |
holdingbranch => { order => 8, label => 'HoldingLibrary' }, |
412 |
homebranch => { order => 9, label => 'HomeLibrary' } |
411 |
); |
413 |
); |
412 |
|
414 |
|
413 |
# We also have some special cases, e.g. itypes that need to show the |
415 |
# We also have some special cases, e.g. itypes that need to show the |
414 |
# value rather than the code. |
416 |
# value rather than the code. |
415 |
my @itypes = Koha::ItemTypes->search; |
417 |
my @itypes = Koha::ItemTypes->search; |
|
|
418 |
my @libraries = Koha::Libraries->search; |
419 |
my $library_names = { map { $_->branchcode => $_->branchname } @libraries }; |
416 |
my @locations = Koha::AuthorisedValues->search( { category => 'LOC' } ); |
420 |
my @locations = Koha::AuthorisedValues->search( { category => 'LOC' } ); |
417 |
my $opac = C4::Context->interface eq 'opac' ; |
421 |
my $opac = C4::Context->interface eq 'opac' ; |
418 |
my %special = ( |
422 |
my %special = ( |
419 |
itype => { map { $_->itemtype => $_->description } @itypes }, |
423 |
itype => { map { $_->itemtype => $_->description } @itypes }, |
420 |
location => { map { $_->authorised_value => ( $opac ? ( $_->lib_opac || $_->lib ) : $_->lib ) } @locations }, |
424 |
location => { map { $_->authorised_value => ( $opac ? ( $_->lib_opac || $_->lib ) : $_->lib ) } @locations }, |
|
|
425 |
holdingbranch => $library_names, |
426 |
homebranch => $library_names |
421 |
); |
427 |
); |
422 |
my @facets; |
428 |
my @facets; |
423 |
$exp_facet //= ''; |
429 |
$exp_facet //= ''; |