diff options
author | ivan <ivan> | 2007-01-15 07:53:54 +0000 |
---|---|---|
committer | ivan <ivan> | 2007-01-15 07:53:54 +0000 |
commit | db690b75431c6bcff432930db1646f316d2e7154 (patch) | |
tree | 210597aaf298f0b25a0b0fd2a3903adf7ba646e7 /httemplate/misc | |
parent | a37da3d6492e60f723b277b90565abc34d8990d6 (diff) |
add batch expiration date incrementer for 295
Diffstat (limited to 'httemplate/misc')
-rw-r--r-- | httemplate/misc/download-batch.cgi | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/httemplate/misc/download-batch.cgi b/httemplate/misc/download-batch.cgi index 7e6750c58..74805b2a8 100644 --- a/httemplate/misc/download-batch.cgi +++ b/httemplate/misc/download-batch.cgi @@ -87,7 +87,13 @@ % % $cust_pay_batch->exp =~ /^\d{2}(\d{2})[\/\-](\d+)[\/\-]\d+$/; % my( $mon, $y ) = ( $2, $1 ); -% $mon = "0$mon" if $mon < 10; +% if ( $conf->exists('batch-increment_expiration') ) { +% my( $curmon, $curyear ) = (localtime(time))[4,5]; +% $curmon++; $curyear-=100; +% $y++ while $y < $curyear || ( $y == $curyear && $mon < $curmon ); +% } +% $mon = "0$mon" if $mon =~ /^\d$/; +% $y = "0$y" if $y =~ /^\d$/; % my $exp = "$mon$y"; % $batchcount++; % $batchtotal += $cust_pay_batch->amount; |