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

(-)a/opac/opac-detail.pl (-2 / +12 lines)
Lines 70-78 my ( $template, $borrowernumber, $cookie ) = get_template_and_user( Link Here
70
    }
70
    }
71
);
71
);
72
72
73
my $biblionumber = $query->param('biblionumber') || $query->param('bib');
73
my $biblionumber = $query->param('biblionumber') || $query->param('bib') || 0;
74
$biblionumber = int($biblionumber);
74
$biblionumber = int($biblionumber);
75
75
76
my @itemsmatchingbiblionumber = GetItemsInfo($biblionumber);
77
if (scalar @itemsmatchingbiblionumber >= 1) {
78
    my @items2hide = GetHiddenItemnumbers(@itemsmatchingbiblionumber);
79
80
    if (scalar @items2hide == scalar @itemsmatchingbiblionumber ) {
81
        # biblionumber=0 effectively hides the biblio record
82
        # since there is no such biblionumber.
83
        $biblionumber = 0;
84
    }
85
}
86
76
my $record       = GetMarcBiblio($biblionumber);
87
my $record       = GetMarcBiblio($biblionumber);
77
if ( ! $record ) {
88
if ( ! $record ) {
78
    print $query->redirect("/cgi-bin/koha/errors/404.pl"); # escape early
89
    print $query->redirect("/cgi-bin/koha/errors/404.pl"); # escape early
79
- 

Return to bug 10584