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

(-)a/C4/Serials.pm (-1 / +1 lines)
Lines 20-26 package C4::Serials; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
22
23
use C4::Auth qw(haspermission);
24
use C4::Context;
23
use C4::Context;
25
use DateTime;
24
use DateTime;
26
use Date::Calc qw(:all);
25
use Date::Calc qw(:all);
Lines 2690-2695 sub _can_do_on_subscription { Link Here
2690
    my $flags = C4::Context->userenv->{flags};
2689
    my $flags = C4::Context->userenv->{flags};
2691
    $userid ||= C4::Context->userenv->{'id'};
2690
    $userid ||= C4::Context->userenv->{'id'};
2692
2691
2692
    require C4::Auth;
2693
    if ( C4::Context->preference('IndependentBranches') ) {
2693
    if ( C4::Context->preference('IndependentBranches') ) {
2694
        return 1
2694
        return 1
2695
          if C4::Context->IsSuperLibrarian()
2695
          if C4::Context->IsSuperLibrarian()
(-)a/Koha/Virtualshelf.pm (-3 / +1 lines)
Lines 19-26 use Modern::Perl; Link Here
19
19
20
use Carp;
20
use Carp;
21
21
22
use C4::Auth;
23
24
use Koha::Patrons;
22
use Koha::Patrons;
25
use Koha::Database;
23
use Koha::Database;
26
use Koha::DateUtils qw( dt_from_string );
24
use Koha::DateUtils qw( dt_from_string );
Lines 243-248 sub can_be_deleted { Link Here
243
241
244
    my $patron = Koha::Patrons->find( $borrowernumber );
242
    my $patron = Koha::Patrons->find( $borrowernumber );
245
243
244
    require C4::Auth;
246
    return 1 if $self->category == $PUBLIC and C4::Auth::haspermission( $patron->userid, { lists => 'delete_public_lists' } );
245
    return 1 if $self->category == $PUBLIC and C4::Auth::haspermission( $patron->userid, { lists => 'delete_public_lists' } );
247
246
248
    return 0;
247
    return 0;
249
- 

Return to bug 18445