|
Lines 24-29
use CGI;
Link Here
|
| 24 |
|
24 |
|
| 25 |
use C4::Auth qw( get_template_and_user ); |
25 |
use C4::Auth qw( get_template_and_user ); |
| 26 |
use C4::Output qw( output_html_with_http_headers ); |
26 |
use C4::Output qw( output_html_with_http_headers ); |
|
|
27 |
use C4::Log qw( logaction ); |
| 27 |
use Koha::Checkouts; |
28 |
use Koha::Checkouts; |
| 28 |
use Koha::DateUtils qw( dt_from_string output_pref ); |
29 |
use Koha::DateUtils qw( dt_from_string output_pref ); |
| 29 |
|
30 |
|
|
Lines 132-137
elsif ( $op eq 'modify' ) {
Link Here
|
| 132 |
$new_hard_due_date &&= dt_from_string($new_hard_due_date); |
133 |
$new_hard_due_date &&= dt_from_string($new_hard_due_date); |
| 133 |
my $checkouts = |
134 |
my $checkouts = |
| 134 |
Koha::Checkouts->search( { issue_id => { -in => \@issue_ids } } ); |
135 |
Koha::Checkouts->search( { issue_id => { -in => \@issue_ids } } ); |
|
|
136 |
my $RenewalLog = C4::Context->preference('RenewalLog'); |
| 135 |
while ( my $checkout = $checkouts->next ) { |
137 |
while ( my $checkout = $checkouts->next ) { |
| 136 |
my $new_due_date = calc_new_due_date( |
138 |
my $new_due_date = calc_new_due_date( |
| 137 |
{ |
139 |
{ |
|
Lines 146-151
elsif ( $op eq 'modify' ) {
Link Here
|
| 146 |
|
148 |
|
| 147 |
# Update items.onloan |
149 |
# Update items.onloan |
| 148 |
$checkout->item->onloan($new_due_date)->store; |
150 |
$checkout->item->onloan($new_due_date)->store; |
|
|
151 |
|
| 152 |
logaction("CIRCULATION", "RENEWAL", $checkout->borrowernumber, $checkout->itemnumber) if $RenewalLog; |
| 149 |
} |
153 |
} |
| 150 |
|
154 |
|
| 151 |
$template->param( |
155 |
$template->param( |
| 152 |
- |
|
|