Bugzilla – Attachment 19651 Details for
Bug 10419
There is no cronjob script for deleting patrons
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10419: Add the branchcode parameter.
Bug-10419-Add-the-branchcode-parameter.patch (text/plain), 2.40 KB, created by
Kyle M Hall (khall)
on 2013-07-15 12:29:29 UTC
(
hide
)
Description:
Bug 10419: Add the branchcode parameter.
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2013-07-15 12:29:29 UTC
Size:
2.40 KB
patch
obsolete
>From 3ef80f52243d1332fce701bff7e0fd0a409c2c48 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Mon, 15 Jul 2013 09:28:40 +0200 >Subject: [PATCH] Bug 10419: Add the branchcode parameter. > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > misc/cronjobs/delete_patrons.pl | 12 +++++++++--- > 1 files changed, 9 insertions(+), 3 deletions(-) > >diff --git a/misc/cronjobs/delete_patrons.pl b/misc/cronjobs/delete_patrons.pl >index 2d869f5..526028b 100755 >--- a/misc/cronjobs/delete_patrons.pl >+++ b/misc/cronjobs/delete_patrons.pl >@@ -9,13 +9,14 @@ use C4::Members; > use Koha::DateUtils; > > my ( $help, $verbose, $not_borrowered_since, $expired_before, $category_code, >- $confirm ); >+ $branchcode, $confirm ); > GetOptions( > 'h|help' => \$help, > 'v|verbose' => \$verbose, > 'not_borrowered_since:s' => \$not_borrowered_since, > 'expired_before:s' => \$expired_before, > 'category_code:s' => \$category_code, >+ 'branchcode:s' => \$branchcode, > 'c|confirm' => \$confirm, > ) || pod2usage(1); > >@@ -29,7 +30,7 @@ $not_borrowered_since = dt_from_string( $not_borrowered_since, 'iso' ) > $expired_before = dt_from_string( $expired_before, 'iso' ) > if $expired_before; > >-unless ( $not_borrowered_since or $expired_before or $category_code ) { >+unless ( $not_borrowered_since or $expired_before or $category_code or $branchcode ) { > pod2usage(q{At least one filter is mandatory}); > exit; > } >@@ -39,6 +40,7 @@ my $members = GetBorrowersToExpunge( > not_borrowered_since => $not_borrowered_since, > expired_before => $expired_before, > category_code => $category_code, >+ branchcode => $branchcode, > } > ); > >@@ -72,7 +74,7 @@ delete_patrons - This script deletes patrons > > =head1 SYNOPSIS > >-delete_patrons.pl [-h -v -c] --not_borrowered_since=2013-07-21 --expired_before=2013-07-21 --category_code=CAT >+delete_patrons.pl [-h -v -c] --not_borrowered_since=2013-07-21 --expired_before=2013-07-21 --category_code=CAT --branchcode=CPL > > dates can be generated with `date -d '-3 month' "+%Y-%m-%d"` > >@@ -98,6 +100,10 @@ Delete patrons with an account expired before this date. > > Delete patrons who have this category code. > >+=item B<--branchcode> >+ >+Delete patrons in this library. >+ > =item B<-c|--confirm> > > Without this flag set, this script will do nothing. >-- >1.7.2.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 10419
:
18677
|
18725
|
18743
|
18754
|
18990
|
19635
|
19651
|
20112
|
20113
|
20114
|
20115
|
20133
|
20134
|
20135
|
20136
|
20137
|
20138
|
20294
|
20295
|
20296
|
20297
|
21658
|
21765
|
21766
|
21773
|
21774
|
21780
|
21781
|
21782
|
21783
|
21784
|
21785
|
21786
|
21787