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

(-)a/misc/cronjobs/writeoff_debts.pl (-5 / +2 lines)
Lines 24-30 GetOptions( Link Here
24
);
24
);
25
@type = split( /,/, join( ',', @type ) );
25
@type = split( /,/, join( ',', @type ) );
26
26
27
pod2usage(1) if ( $help || !$file && !@type && !$before && !$after );
27
pod2usage(1) if ( $help || !$file && !@type && !$before && !$after && !@category_code );
28
28
29
my $where = { 'amountoutstanding' => { '>' => 0 } };
29
my $where = { 'amountoutstanding' => { '>' => 0 } };
30
my $attr = {};
30
my $attr = {};
Lines 67-73 if (@category_code) { Link Here
67
67
68
my $lines = Koha::Account::Lines->search( $where, $attr );
68
my $lines = Koha::Account::Lines->search( $where, $attr );
69
69
70
$verbose //= !$confirm;
71
if ( $verbose ) {
70
if ( $verbose ) {
72
    print "Attempting to write off " . $lines->count . " debts" if $confirm;
71
    print "Attempting to write off " . $lines->count . " debts" if $confirm;
73
    print "With --confirm we would write off " . $lines->count . " debts" if !$confirm;
72
    print "With --confirm we would write off " . $lines->count . " debts" if !$confirm;
Lines 202-209 This flag set the script to output logging for the actions it will perform. Link Here
202
=item B<-c|--confirm>
201
=item B<-c|--confirm>
203
202
204
This flag must be provided in order for the script to actually
203
This flag must be provided in order for the script to actually
205
writeoff debts.  If it is not supplied, the script will
204
writeoff debts.  
206
only report on the accountline records it would have been written off.
207
205
208
=back
206
=back
209
207
210
- 

Return to bug 34077