Lines 198-206
my @biblionumbers = uniq $distinct_holds->get_column('biblionumber');
Link Here
|
198 |
# make final reserves hash and fill with info |
198 |
# make final reserves hash and fill with info |
199 |
my $reserves; |
199 |
my $reserves; |
200 |
foreach my $bibnum ( @biblionumbers ){ |
200 |
foreach my $bibnum ( @biblionumbers ){ |
201 |
|
|
|
202 |
my @branchtransfers = map { $_->itemnumber } Koha::Item::Transfers->search({ datearrived => undef }, { columns => [ 'itemnumber' ], collapse => 1 }); |
201 |
my @branchtransfers = map { $_->itemnumber } Koha::Item::Transfers->search({ datearrived => undef }, { columns => [ 'itemnumber' ], collapse => 1 }); |
203 |
my @checkouts = map { $_->itemnumber } Koha::Checkouts->search({}, { columns => [ 'itemnumber' ], collapse => 1 }); |
|
|
204 |
my @waiting_holds = map { $_->itemnumber } Koha::Holds->search({'found' => 'W'}, { columns => [ 'itemnumber' ], collapse => 1 }); |
202 |
my @waiting_holds = map { $_->itemnumber } Koha::Holds->search({'found' => 'W'}, { columns => [ 'itemnumber' ], collapse => 1 }); |
205 |
|
203 |
|
206 |
my @items = Koha::Items->search( |
204 |
my @items = Koha::Items->search( |
Lines 209-215
foreach my $bibnum ( @biblionumbers ){
Link Here
|
209 |
itemlost => 0, |
207 |
itemlost => 0, |
210 |
withdrawn => 0, |
208 |
withdrawn => 0, |
211 |
notforloan => 0, |
209 |
notforloan => 0, |
212 |
itemnumber => { -not_in => [ @branchtransfers, @checkouts, @waiting_holds ] }, |
210 |
onloan => undef, |
|
|
211 |
itemnumber => { -not_in => [ @branchtransfers, @waiting_holds ] }, |
213 |
} |
212 |
} |
214 |
); |
213 |
); |
215 |
|
214 |
|
216 |
- |
|
|