Parcourir la source

Bug 26963: (QA follow-up) Fix cases where we expected a list

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
tags/v20.11.00
Nick Clemens il y a 5 mois
Parent
révision
7a42c85889
3 fichiers modifiés avec 3 ajouts et 3 suppressions
  1. +1
    -1
      Koha/Biblio.pm
  2. +1
    -1
      Koha/Template/Plugin/Branches.pm
  3. +1
    -1
      reserve/request.pl

+ 1
- 1
Koha/Biblio.pm Voir le fichier

@@ -220,7 +220,7 @@ sub pickup_locations {

my @pickup_locations;
foreach my $item_of_bib ($self->items->as_list) {
push @pickup_locations, @{ $item_of_bib->pickup_locations( {patron => $patron} ) };
push @pickup_locations, @{ $item_of_bib->pickup_locations( {patron => $patron} )->as_list() };
}

my %seen;


+ 1
- 1
Koha/Template/Plugin/Branches.pm Voir le fichier

@@ -117,7 +117,7 @@ sub pickup_locations {
if ($item) {
$item = Koha::Items->find($item)
unless ref($item) eq 'Koha::Item';
@libraries = @{ $item->pickup_locations( { patron => $patron } ) }
@libraries = $item->pickup_locations( { patron => $patron } )
if defined $item;
}
elsif ($biblio) {


+ 1
- 1
reserve/request.pl Voir le fichier

@@ -572,7 +572,7 @@ foreach my $biblionumber (@biblionumbers) {
$item->{pickup_locations_code} = 'all';
} else {
my $arr_locations = Koha::Items->find($itemnumber)
->pickup_locations( { patron => $patron } );
->pickup_locations( { patron => $patron } )->as_list();

$item->{pickup_locations} = join( ', ',
map { $_->unblessed->{branchname} } @$arr_locations);


Chargement…
Annuler
Enregistrer