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

(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt (-12 / +14 lines)
Lines 249-266 Link Here
249
                                                            <span class="date-format to" data-biblionumber="[% bibitemloo.biblionumber %]">[% INCLUDE 'date-format.inc' %]</span>
249
                                                            <span class="date-format to" data-biblionumber="[% bibitemloo.biblionumber %]">[% INCLUDE 'date-format.inc' %]</span>
250
                                                        </li>
250
                                                        </li>
251
251
252
                                                        [% UNLESS ( multi_hold ) %]
252
                                                        [% IF Koha.Preference('AllowHoldItemTypeSelection') %]
253
                                                            [% IF Koha.Preference('AllowHoldItemTypeSelection') %]
253
                                                            [% itemtypes = [] %]
254
                                                                <li>
254
                                                            [% FOREACH item IN bibitemloo.itemLoop %]
255
                                                                    <label for="itemtype">Request specific item type:</label>
255
                                                                [% itemtypes.push( item.itype ) %]
256
                                                                    <select name="itemtype" size="1" id="itemtype">
256
                                                            [%- END %]
257
                                                                        <option value="">Any item type</option>
257
                                                            <li>
258
                                                                        [%- FOREACH itemtype IN available_itemtypes %]
258
                                                                <label for="itemtype">Request specific item type:</label>
259
                                                                            <option value="[% itemtype %]">[% ItemTypes.GetDescription( itemtype ) %]</option>
259
                                                                <select name="itemtype" size="1" id="itemtype">
260
                                                                        [%- END %]
260
                                                                    <option value="">Any item type</option>
261
                                                                    </select>
261
                                                                    [% FOREACH i IN itemtypes.unique.sort %]
262
                                                                </li>
262
                                                                        <option value="[% i %]">[% ItemTypes.GetDescription( i ) %]</option>
263
                                                            [% END %]
263
                                                                    [%- END %]
264
                                                                </select>
265
                                                            </li>
264
                                                        [% END %]
266
                                                        [% END %]
265
267
266
                                                        [% IF ( OpacHoldNotes ) %]
268
                                                        [% IF ( OpacHoldNotes ) %]
(-)a/opac/opac-reserve.pl (-5 / +1 lines)
Lines 383-389 unless ($noreserves) { Link Here
383
#
383
#
384
my $notforloan_label_of = get_notforloan_label_of();
384
my $notforloan_label_of = get_notforloan_label_of();
385
385
386
my @available_itemtypes;
387
my $biblioLoop = [];
386
my $biblioLoop = [];
388
my $numBibsAvailable = 0;
387
my $numBibsAvailable = 0;
389
my $itemdata_enumchron = 0;
388
my $itemdata_enumchron = 0;
Lines 444-449 foreach my $biblioNum (@biblionumbers) { Link Here
444
        $itemLoopIter->{copynumber} = $itemInfo->{copynumber};
443
        $itemLoopIter->{copynumber} = $itemInfo->{copynumber};
445
        if ($itemLevelTypes) {
444
        if ($itemLevelTypes) {
446
            $itemLoopIter->{translated_description} = $itemInfo->{translated_description};
445
            $itemLoopIter->{translated_description} = $itemInfo->{translated_description};
446
            $itemLoopIter->{itype} = $itemInfo->{itype};
447
            $itemLoopIter->{imageurl} = $itemInfo->{imageurl};
447
            $itemLoopIter->{imageurl} = $itemInfo->{imageurl};
448
        }
448
        }
449
449
Lines 537-543 foreach my $biblioNum (@biblionumbers) { Link Here
537
                $itemLoopIter->{available} = 1;
537
                $itemLoopIter->{available} = 1;
538
                $numCopiesOPACAvailable++;
538
                $numCopiesOPACAvailable++;
539
                $biblioLoopIter{force_hold} = 1 if $hold_allowed eq 'F';
539
                $biblioLoopIter{force_hold} = 1 if $hold_allowed eq 'F';
540
                push( @available_itemtypes, $itemInfo->{itype} );
541
            }
540
            }
542
            $numCopiesAvailable++;
541
            $numCopiesAvailable++;
543
        }
542
        }
Lines 575-582 foreach my $biblioNum (@biblionumbers) { Link Here
575
    $anyholdable = 1 if $biblioLoopIter{holdable};
574
    $anyholdable = 1 if $biblioLoopIter{holdable};
576
}
575
}
577
576
578
@available_itemtypes = uniq( @available_itemtypes );
579
$template->param( available_itemtypes => \@available_itemtypes );
580
577
581
if ( $numBibsAvailable == 0 || $anyholdable == 0) {
578
if ( $numBibsAvailable == 0 || $anyholdable == 0) {
582
    $template->param( none_available => 1 );
579
    $template->param( none_available => 1 );
583
- 

Return to bug 15533