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

(-)a/opac/opac-ISBDdetail.pl (-2 / +2 lines)
Lines 93-100 if (scalar @items >= 1) { Link Here
93
    if ( C4::Context->preference('OpacHiddenItemsExceptions') ) {
93
    if ( C4::Context->preference('OpacHiddenItemsExceptions') ) {
94
94
95
        # we need to fetch the borrower info here, so we can pass the category
95
        # we need to fetch the borrower info here, so we can pass the category
96
        my $borrower = GetMember( borrowernumber => $borrowernumber );
96
        my $borrower = Koha::Patrons->find( { borrowernumber => $borrowernumber } );
97
        $borcat = $borrower->{categorycode};
97
        $borcat = $borrower->categorycode;
98
    }
98
    }
99
99
100
    my @hiddenitems = GetHiddenItemnumbers( { items => \@items, borcat => $borcat });
100
    my @hiddenitems = GetHiddenItemnumbers( { items => \@items, borcat => $borcat });
(-)a/opac/opac-MARCdetail.pl (-2 / +2 lines)
Lines 88-95 if (scalar @all_items >= 1) { Link Here
88
    if ( C4::Context->preference('OpacHiddenItemsExceptions') ) {
88
    if ( C4::Context->preference('OpacHiddenItemsExceptions') ) {
89
89
90
        # we need to fetch the borrower info here, so we can pass the category
90
        # we need to fetch the borrower info here, so we can pass the category
91
        my $borrower = GetMember( borrowernumber => $borrowernumber );
91
        my $borrower = Koha::Patrons->find( { borrowernumber => $borrowernumber } );
92
        $borcat = $borrower->{categorycode};
92
        $borcat = $borrower->categorycode;
93
    }
93
    }
94
    push @items2hide, GetHiddenItemnumbers({ items => \@all_items, borcat => $borcat });
94
    push @items2hide, GetHiddenItemnumbers({ items => \@all_items, borcat => $borcat });
95
95
(-)a/opac/opac-detail.pl (-2 / +2 lines)
Lines 86-93 if ( scalar @all_items >= 1 ) { Link Here
86
    if ( C4::Context->preference('OpacHiddenItemsExceptions') ) {
86
    if ( C4::Context->preference('OpacHiddenItemsExceptions') ) {
87
87
88
        # we need to fetch the borrower info here, so we can pass the category
88
        # we need to fetch the borrower info here, so we can pass the category
89
        my $borrower = GetMember( borrowernumber => $borrowernumber );
89
        my $borrower = Koha::Patrons->find( { borrowernumber => $borrowernumber } );
90
        $borcat = $borrower->{categorycode};
90
        $borcat = $borrower->categorycode;
91
    }
91
    }
92
92
93
    push @hiddenitems,
93
    push @hiddenitems,
(-)a/opac/opac-search.pl (-4 / +3 lines)
Lines 51-58 use C4::Koha; Link Here
51
use C4::Tags qw(get_tags);
51
use C4::Tags qw(get_tags);
52
use C4::SocialData;
52
use C4::SocialData;
53
use C4::External::OverDrive;
53
use C4::External::OverDrive;
54
use C4::Members qw(GetMember);
55
54
55
use Koha::Libraries;
56
use Koha::ItemTypes;
56
use Koha::ItemTypes;
57
use Koha::LibraryCategories;
57
use Koha::LibraryCategories;
58
use Koha::Ratings;
58
use Koha::Ratings;
Lines 632-639 my $search_context = {}; Link Here
632
$search_context->{'interface'} = 'opac';
632
$search_context->{'interface'} = 'opac';
633
if (C4::Context->preference('OpacHiddenItemsExceptions')){
633
if (C4::Context->preference('OpacHiddenItemsExceptions')){
634
    # we need to fetch the borrower info here, so we can pass the category
634
    # we need to fetch the borrower info here, so we can pass the category
635
    my $borrower = GetMember( borrowernumber => $borrowernumber );
635
    my $borrower = Koha::Patrons->find( { borrowernumber => $borrowernumber } );
636
    $search_context->{'category'} = $borrower->{'categorycode'};
636
    $search_context->{'category'} = $borrower->categorycode;
637
}
637
}
638
638
639
for (my $i=0;$i<@servers;$i++) {
639
for (my $i=0;$i<@servers;$i++) {
640
- 

Return to bug 14385