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

(-)a/C4/HoldsQueue.pm (-5 / +6 lines)
Lines 277-283 sub GetPendingHoldRequestsForBib { Link Here
277
    my $dbh = C4::Context->dbh;
277
    my $dbh = C4::Context->dbh;
278
278
279
    my $request_query = "SELECT biblionumber, borrowernumber, itemnumber, priority, reserves.branchcode,
279
    my $request_query = "SELECT biblionumber, borrowernumber, itemnumber, priority, reserves.branchcode,
280
                                reservedate, reservenotes, borrowers.branchcode AS borrowerbranch, itemtype
280
                                reservedate, reservenotes, borrowers.branchcode AS borrowerbranch, itemtype, item_level_hold
281
                         FROM reserves
281
                         FROM reserves
282
                         JOIN borrowers USING (borrowernumber)
282
                         JOIN borrowers USING (borrowernumber)
283
                         WHERE biblionumber = ?
283
                         WHERE biblionumber = ?
Lines 409-414 sub MapItemsToHoldRequests { Link Here
409
                  || ( $item->{holdallowed} == 1
409
                  || ( $item->{holdallowed} == 1
410
                    && $item->{homebranch} ne $request->{borrowerbranch} );
410
                    && $item->{homebranch} ne $request->{borrowerbranch} );
411
411
412
                next if $request->{itemnumber} && $request->{itemnumber} != $item->{itemnumber};
413
412
                next unless $item->{_object}->can_be_transferred( { to => $libraries->{ $request->{branchcode} } } );
414
                next unless $item->{_object}->can_be_transferred( { to => $libraries->{ $request->{branchcode} } } );
413
415
414
                my $local_holds_priority_item_branchcode =
416
                my $local_holds_priority_item_branchcode =
Lines 436-442 sub MapItemsToHoldRequests { Link Here
436
                            holdingbranch  => $item->{holdingbranch},
438
                            holdingbranch  => $item->{holdingbranch},
437
                            pickup_branch  => $request->{branchcode}
439
                            pickup_branch  => $request->{branchcode}
438
                              || $request->{borrowerbranch},
440
                              || $request->{borrowerbranch},
439
                            item_level   => 0,
441
                            item_level   => $request->{item_level_hold},
440
                            reservedate  => $request->{reservedate},
442
                            reservedate  => $request->{reservedate},
441
                            reservenotes => $request->{reservenotes},
443
                            reservenotes => $request->{reservenotes},
442
                        };
444
                        };
Lines 475-481 sub MapItemsToHoldRequests { Link Here
475
                    biblionumber   => $request->{biblionumber},
477
                    biblionumber   => $request->{biblionumber},
476
                    holdingbranch  => $items_by_itemnumber{ $request->{itemnumber} }->{holdingbranch},
478
                    holdingbranch  => $items_by_itemnumber{ $request->{itemnumber} }->{holdingbranch},
477
                    pickup_branch  => $request->{branchcode} || $request->{borrowerbranch},
479
                    pickup_branch  => $request->{branchcode} || $request->{borrowerbranch},
478
                    item_level     => 1,
480
                    item_level     => $request->{item_level_hold},
479
                    reservedate    => $request->{reservedate},
481
                    reservedate    => $request->{reservedate},
480
                    reservenotes   => $request->{reservenotes},
482
                    reservenotes   => $request->{reservenotes},
481
                };
483
                };
Lines 650-656 sub MapItemsToHoldRequests { Link Here
650
                biblionumber => $request->{biblionumber},
652
                biblionumber => $request->{biblionumber},
651
                holdingbranch => $holdingbranch,
653
                holdingbranch => $holdingbranch,
652
                pickup_branch => $pickup_branch,
654
                pickup_branch => $pickup_branch,
653
                item_level => 0,
655
                item_level => $request->{item_level_hold},
654
                reservedate => $request->{reservedate},
656
                reservedate => $request->{reservedate},
655
                reservenotes => $request->{reservenotes},
657
                reservenotes => $request->{reservenotes},
656
            };
658
            };
657
- 

Return to bug 25783