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

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt (-1 / +11 lines)
Lines 227-233 Link Here
227
                            <li>
227
                            <li>
228
                                <label for="pickup">Pickup at:</label>
228
                                <label for="pickup">Pickup at:</label>
229
                                <select name="pickup" size="1" id="pickup">
229
                                <select name="pickup" size="1" id="pickup">
230
                                    [% PROCESS options_for_libraries libraries => Branches.all({ selected => pickup, search_params => { pickup_location => 1 } }) %]
230
                                    [% UNLESS ( multi_hold ) %]
231
				        [% PROCESS options_for_libraries libraries => Branches.pickup_locations({ search_params => { biblio => biblionumber, patron => patron }, selected => pickup }) %]
232
				    [% ELSE %]
233
				        [% PROCESS options_for_libraries libraries => Branches.all({ selected => pickup, search_params => { pickup_location => 1 } }) %]
234
				    [% END %]
231
                                </select>
235
                                </select>
232
                            </li>
236
                            </li>
233
237
Lines 341-346 Link Here
341
                                                <th>Vol no.</th>
345
                                                <th>Vol no.</th>
342
                                            [% END %]
346
                                            [% END %]
343
                                            <th class="title-string">Information</th>
347
                                            <th class="title-string">Information</th>
348
					    <th class="title-string">Allowed pickup locations</th>
344
                                        </tr>
349
                                        </tr>
345
                                    </thead>
350
                                    </thead>
346
                                    <tbody>
351
                                    <tbody>
Lines 377-382 Link Here
377
                                                                        Not holdable
382
                                                                        Not holdable
378
                                                                    [% ELSIF itemloo.not_holdable == 'cannotReserveFromOtherBranches' %]
383
                                                                    [% ELSIF itemloo.not_holdable == 'cannotReserveFromOtherBranches' %]
379
                                                                        Patron is from different library
384
                                                                        Patron is from different library
385
								    [% ELSIF itemloo.not_holdable == 'branchNotInHoldGroup' %]
386
									Cannot place hold from patrons's library
380
                                                                    [% ELSIF itemloo.not_holdable == 'itemAlreadyOnHold' %]
387
                                                                    [% ELSIF itemloo.not_holdable == 'itemAlreadyOnHold' %]
381
                                                                        Patron already has hold for this item
388
                                                                        Patron already has hold for this item
382
                                                                    [% ELSIF itemloo.not_holdable == 'cannotBeTransferred' %]
389
                                                                    [% ELSIF itemloo.not_holdable == 'cannotBeTransferred' %]
Lines 474-479 Link Here
474
                                                           <span class="nfl">Not for loan ([% AuthorisedValues.GetByCode( 'NOT_LOAN', itemloo.notforloan ) | html %])</span>
481
                                                           <span class="nfl">Not for loan ([% AuthorisedValues.GetByCode( 'NOT_LOAN', itemloo.notforloan ) | html %])</span>
475
                                                        [% END %]
482
                                                        [% END %]
476
                                                    </td>
483
                                                    </td>
484
						    <td>
485
						        [% itemloo.pickup_locations | html %]
486
						    </td>
477
                                                </tr>
487
                                                </tr>
478
                                            [% END # / UNLESS itemloo.hide %]
488
                                            [% END # / UNLESS itemloo.hide %]
479
                                        [% END # /FOREACH itemloo %]
489
                                        [% END # /FOREACH itemloo %]
(-)a/reserve/request.pl (-3 / +7 lines)
Lines 227-233 foreach my $biblionumber (@biblionumbers) { Link Here
227
    my $force_hold_level;
227
    my $force_hold_level;
228
    if ( $patron ) {
228
    if ( $patron ) {
229
        { # CanBookBeReserved
229
        { # CanBookBeReserved
230
            my $canReserve = CanBookBeReserved( $patron->borrowernumber, $biblionumber, $pickup );
230
            my $canReserve = CanBookBeReserved( $patron->borrowernumber, $biblionumber );
231
            if ( $canReserve->{status} eq 'OK' ) {
231
            if ( $canReserve->{status} eq 'OK' ) {
232
232
233
                #All is OK and we can continue
233
                #All is OK and we can continue
Lines 477-483 foreach my $biblionumber (@biblionumbers) { Link Here
477
477
478
                $item->{'holdallowed'} = $branchitemrule->{'holdallowed'};
478
                $item->{'holdallowed'} = $branchitemrule->{'holdallowed'};
479
479
480
                my $can_item_be_reserved = CanItemBeReserved( $patron->borrowernumber, $itemnumber, $pickup );
480
                my $can_item_be_reserved = CanItemBeReserved( $patron->borrowernumber, $itemnumber );
481
                $item->{not_holdable} = $can_item_be_reserved->{status} unless ( $can_item_be_reserved->{status} eq 'OK' );
481
                $item->{not_holdable} = $can_item_be_reserved->{status} unless ( $can_item_be_reserved->{status} eq 'OK' );
482
482
483
                $item->{item_level_holds} = Koha::IssuingRules->get_opacitemholds_policy( { item => $item_object, patron => $patron } );
483
                $item->{item_level_holds} = Koha::IssuingRules->get_opacitemholds_policy( { item => $item_object, patron => $patron } );
Lines 491-496 foreach my $biblionumber (@biblionumbers) { Link Here
491
                {
491
                {
492
                    $item->{available} = 1;
492
                    $item->{available} = 1;
493
                    $num_available++;
493
                    $num_available++;
494
                    if($branchitemrule->{'hold_fulfillment_policy'} eq 'any' ) {
495
                        $item->{pickup_locations} = 'Any library';
496
                    } else {
497
                        $item->{pickup_locations} = join (', ', map { $_->{branchname} } Koha::Items->find($itemnumber)->pickup_locations());
498
                    }
494
499
495
                    push( @available_itemtypes, $item->{itype} );
500
                    push( @available_itemtypes, $item->{itype} );
496
                }
501
                }
497
- 

Return to bug 22284