Lines 50-55
use Koha::DateUtils;
Link Here
|
50 |
use Koha::Calendar; |
50 |
use Koha::Calendar; |
51 |
use Koha::Borrower::Debarments; |
51 |
use Koha::Borrower::Debarments; |
52 |
use Koha::Database; |
52 |
use Koha::Database; |
|
|
53 |
use Koha::Logger; |
53 |
use Carp; |
54 |
use Carp; |
54 |
use List::MoreUtils qw( uniq ); |
55 |
use List::MoreUtils qw( uniq ); |
55 |
use Date::Calc qw( |
56 |
use Date::Calc qw( |
Lines 2792-2797
sub AddRenewal {
Link Here
|
2792 |
my $datedue = shift; |
2793 |
my $datedue = shift; |
2793 |
my $lastreneweddate = shift || DateTime->now(time_zone => C4::Context->tz)->ymd(); |
2794 |
my $lastreneweddate = shift || DateTime->now(time_zone => C4::Context->tz)->ymd(); |
2794 |
|
2795 |
|
|
|
2796 |
my $logger = Koha::Logger->get(); |
2797 |
$logger->trace( "PARAMS: " . Dumper( { borrowernumber => $borrowernumber, itemnumber => $itemnumber, branch => $branch, datedue => $datedue, lastreneweddate => $lastreneweddate } ) ); |
2798 |
|
2795 |
my $item = GetItem($itemnumber) or return; |
2799 |
my $item = GetItem($itemnumber) or return; |
2796 |
my $biblio = GetBiblioFromItemNumber($itemnumber) or return; |
2800 |
my $biblio = GetBiblioFromItemNumber($itemnumber) or return; |
2797 |
|
2801 |
|
Lines 2897-2903
sub AddRenewal {
Link Here
|
2897 |
borrowernumber => $borrowernumber, |
2901 |
borrowernumber => $borrowernumber, |
2898 |
ccode => $item->{'ccode'}} |
2902 |
ccode => $item->{'ccode'}} |
2899 |
); |
2903 |
); |
2900 |
return $datedue; |
2904 |
|
|
|
2905 |
$logger->trace("RETURNING $datedue"); |
2906 |
return $datedue; |
2901 |
} |
2907 |
} |
2902 |
|
2908 |
|
2903 |
sub GetRenewCount { |
2909 |
sub GetRenewCount { |