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

(-)a/Koha/Patrons.pm (-1 / +1 lines)
Lines 71-77 sub search_housebound_deliverers { Link Here
71
    return Koha::Patrons->_new_from_dbic($del);
71
    return Koha::Patrons->_new_from_dbic($del);
72
}
72
}
73
73
74
=head3
74
=head3 search_upcoming_membership_expires
75
75
76
my $patrons = Koha::Patrons->search_upcoming_membership_expires();
76
my $patrons = Koha::Patrons->search_upcoming_membership_expires();
77
77
(-)a/t/db_dependent/Koha/Patrons.t (-3 / +2 lines)
Lines 716-723 subtest 'search_patrons_to_anonymise & anonymise_issue_history' => sub { Link Here
716
        my ( $returned, undef, undef ) = C4::Circulation::AddReturn( $item->{barcode}, undef, undef, undef, '2010-10-10' );
716
        my ( $returned, undef, undef ) = C4::Circulation::AddReturn( $item->{barcode}, undef, undef, undef, '2010-10-10' );
717
        is( $returned, 1, 'The item should have been returned' );
717
        is( $returned, 1, 'The item should have been returned' );
718
718
719
        my $patron_to_anonymise = Koha::Patrons->search_patrons_to_anonymise( '2010-10-11' )->search( { 'me.borrowernumber' => $patron->{borrowernumber} } )->next;
719
        my $patrons_to_anonymise = Koha::Patrons->search_patrons_to_anonymise( '2010-10-11' )->search( { 'me.borrowernumber' => $patron->{borrowernumber} } );
720
        is( ref($patron_to_anonymise), 'Koha::Patron', 'search_patrons_to_anonymise should return Koha::Patrons' );
720
        is( ref($patrons_to_anonymise), 'Koha::Patrons', 'search_patrons_to_anonymise should return Koha::Patrons' );
721
721
722
        my $rows_affected = Koha::Patrons->search_patrons_to_anonymise( '2010-10-11')->anonymise_issue_history('2010-10-11');
722
        my $rows_affected = Koha::Patrons->search_patrons_to_anonymise( '2010-10-11')->anonymise_issue_history('2010-10-11');
723
        ok( $rows_affected > 0, 'AnonymiseIssueHistory should affect at least 1 row' );
723
        ok( $rows_affected > 0, 'AnonymiseIssueHistory should affect at least 1 row' );
724
- 

Return to bug 16966