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

(-)a/misc/cronjobs/cleanup_database.pl (-3 / +5 lines)
Lines 109-115 Usage: $0 [-h|--help] [--confirm] [--sessions] [--sessdays DAYS] [-v|--verbose] Link Here
109
                                    --pseudo-transactions-from YYYY-MM-DD and/or --pseudo-transactions-to YYYY-MM-DD
109
                                    --pseudo-transactions-from YYYY-MM-DD and/or --pseudo-transactions-to YYYY-MM-DD
110
   --labels DAYS           Purge item label batches last added to more than DAYS days ago.
110
   --labels DAYS           Purge item label batches last added to more than DAYS days ago.
111
   --cards DAY             Purge card creator batches last added to more than DAYS days ago.
111
   --cards DAY             Purge card creator batches last added to more than DAYS days ago.
112
112
   --return-claims         Purge all resolved return claims older than the number of days specified in
113
                           the system preference CleanUpDatabaseReturnClaims.
113
USAGE
114
USAGE
114
    exit $_[0];
115
    exit $_[0];
115
}
116
}
Lines 129-135 my $pZ3950; Link Here
129
my $pListShareInvites;
130
my $pListShareInvites;
130
my $pDebarments;
131
my $pDebarments;
131
my $allDebarments;
132
my $allDebarments;
132
my $return_claims = C4::Context->preference('CleanUpDatabaseReturnClaims');
133
my $return_claims;
133
my $pExpSelfReg;
134
my $pExpSelfReg;
134
my $pUnvSelfReg;
135
my $pUnvSelfReg;
135
my $fees_days;
136
my $fees_days;
Lines 186-191 GetOptions( Link Here
186
    'pseudo-transactions-to:s'   => \$pPseudoTransactionsTo,
187
    'pseudo-transactions-to:s'   => \$pPseudoTransactionsTo,
187
    'labels'            => \$labels,
188
    'labels'            => \$labels,
188
    'cards'             => \$cards,
189
    'cards'             => \$cards,
190
    'return-claims'     => \$return_claims,
189
) || usage(1);
191
) || usage(1);
190
192
191
# Use default values
193
# Use default values
Lines 530-535 if ($pStatistics) { Link Here
530
    }
532
    }
531
}
533
}
532
534
535
$return_claims = C4::Context->preference('CleanUpDatabaseReturnClaims') if $return_claims;
533
if ($return_claims) {
536
if ($return_claims) {
534
    print "Purging return claims older than $return_claims days.\n" if $verbose;
537
    print "Purging return claims older than $return_claims days.\n" if $verbose;
535
538
536
- 

Return to bug 25429