Lines 44-49
use Koha::Calendar;
Link Here
|
44 |
use Koha::Libraries; |
44 |
use Koha::Libraries; |
45 |
use Koha::Acquisition::Currencies; |
45 |
use Koha::Acquisition::Currencies; |
46 |
use Koha::Patrons; |
46 |
use Koha::Patrons; |
|
|
47 |
use Koha::Recalls; |
47 |
|
48 |
|
48 |
=head1 NAME |
49 |
=head1 NAME |
49 |
|
50 |
|
Lines 404-409
if ( defined $csvfilename ) {
Link Here
|
404 |
} else { |
405 |
} else { |
405 |
open $csv_fh, ">", $csvfilename or die "unable to open $csvfilename: $!"; |
406 |
open $csv_fh, ">", $csvfilename or die "unable to open $csvfilename: $!"; |
406 |
} |
407 |
} |
|
|
408 |
|
407 |
if ( $csv->combine(qw(name surname address1 address2 zipcode city country email phone cardnumber itemcount itemsinfo branchname letternumber)) ) { |
409 |
if ( $csv->combine(qw(name surname address1 address2 zipcode city country email phone cardnumber itemcount itemsinfo branchname letternumber)) ) { |
408 |
print $csv_fh $csv->string, "\n"; |
410 |
print $csv_fh $csv->string, "\n"; |
409 |
} else { |
411 |
} else { |
Lines 472-477
SELECT biblio.*, items.*, issues.*, biblioitems.itemtype, branchname
Link Here
|
472 |
AND TO_DAYS($date)-TO_DAYS(issues.date_due) >= 0 |
474 |
AND TO_DAYS($date)-TO_DAYS(issues.date_due) >= 0 |
473 |
END_SQL |
475 |
END_SQL |
474 |
|
476 |
|
|
|
477 |
|
475 |
my $query = "SELECT * FROM overduerules WHERE delay1 IS NOT NULL AND branchcode = ? "; |
478 |
my $query = "SELECT * FROM overduerules WHERE delay1 IS NOT NULL AND branchcode = ? "; |
476 |
$query .= " AND categorycode IN (".join( ',' , ('?') x @myborcat ).") " if (@myborcat); |
479 |
$query .= " AND categorycode IN (".join( ',' , ('?') x @myborcat ).") " if (@myborcat); |
477 |
$query .= " AND categorycode NOT IN (".join( ',' , ('?') x @myborcatout ).") " if (@myborcatout); |
480 |
$query .= " AND categorycode NOT IN (".join( ',' , ('?') x @myborcatout ).") " if (@myborcatout); |
Lines 624-630
END_SQL
Link Here
|
624 |
my $itemcount = 0; |
627 |
my $itemcount = 0; |
625 |
my $titles = ""; |
628 |
my $titles = ""; |
626 |
my @items = (); |
629 |
my @items = (); |
627 |
|
630 |
|
628 |
my $j = 0; |
631 |
my $j = 0; |
629 |
my $exceededPrintNoticesMaxLines = 0; |
632 |
my $exceededPrintNoticesMaxLines = 0; |
630 |
while ( my $item_info = $sth2->fetchrow_hashref() ) { |
633 |
while ( my $item_info = $sth2->fetchrow_hashref() ) { |
Lines 671-676
END_SQL
Link Here
|
671 |
} |
674 |
} |
672 |
$sth2->finish; |
675 |
$sth2->finish; |
673 |
|
676 |
|
|
|
677 |
foreach my $item (@items) { |
678 |
my $recall = Koha::Recalls->find({ itemnumber => $item->{itemnumber} }); |
679 |
if (defined $recall){ |
680 |
$recall->update({ status => 'O' }); |
681 |
} |
682 |
} |
683 |
|
674 |
my @message_transport_types = @{ GetOverdueMessageTransportTypes( $branchcode, $overdue_rules->{categorycode}, $i) }; |
684 |
my @message_transport_types = @{ GetOverdueMessageTransportTypes( $branchcode, $overdue_rules->{categorycode}, $i) }; |
675 |
@message_transport_types = @{ GetOverdueMessageTransportTypes( q{}, $overdue_rules->{categorycode}, $i) } |
685 |
@message_transport_types = @{ GetOverdueMessageTransportTypes( q{}, $overdue_rules->{categorycode}, $i) } |
676 |
unless @message_transport_types; |
686 |
unless @message_transport_types; |
677 |
- |
|
|