[Bug 14292] New: Add --category and --skip-category options to longoverdue.pl to include or exclude borrower categories.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Bug ID: 14292 Summary: Add --category and --skip-category options to longoverdue.pl to include or exclude borrower categories. Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Command-line Utilities Assignee: gmcharlt@gmail.com Reporter: barton@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org Intention of development: To be able to mark items as long overdue if the patron is not of a given patron category Plan of attack: 1) Add new option --category to list only patron categories to act upon 2) Add new option --skip-category to list any patron categories to *not* act upon -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|gmcharlt@gmail.com |barton@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Tom Misilo <misilot@fit.edu> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |misilot@fit.edu -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Nicole Engard (ByWater) <nicole@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nicole@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Nicole C. Engard <nengard@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED CC| |nengard@gmail.com Change sponsored?|--- |Sponsored -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #1 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 42125 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=42125&action=edit Add patron category restrictions to longoverdue.pl Add command line options --category and --skip-category Convert usage() to pod2usage. (This was previous FIXME) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff --- Comment #2 from Barton Chittenden <barton@bywatersolutions.com> --- Prerequisites for testing: Several borrower categories defined (Let's call them ADULT, STAFF, CHILD) Borrowers defined in each category (AA -- ADULT, SS -- STAFF, CC -- CHILD) Items available for checkout. Make sure that you are using the default authorised value 2 as "Long Overdue (Lost)" Apply patch Make sure that $KOHA_CONF and $PERL5LIB are set correctly. Test plan: 1) Check out items to AA, SS and CC. Backdate the check-ins so that the due date more than 90 days prior (2015-05-01 is a practical date, if testing in 2015). Note the borrower number and item number for each checkout. 2) Run longoverdue.pl in verbose without the --confirm option: ./misc/cronjobs/longoverdue.pl -l 90=2 -v ### TEST MODE -- NO ACTIONS TAKEN ### Range 1 Due 90 - 366 days ago (2014-08-30 to 2015-06-02), lost => 2 Due 2015-04-01 23:59:00: item # from borrower ## to lost: 2 Due 2015-05-01 23:59:00: item # from borrower ## to lost: 2 Due 2015-05-01 23:59:00: item # from borrower ## to lost: 2 3) Run longoverdue.pl without --confirm using --category STAFF: ./misc/cronjobs/longoverdue.pl -l 90=2 -v --category STAFF You should see the item checked out to STAFF set as lost, but the other two items will not be processed. 4) Run longoverdue.pl without --confirm using --skip-category STAFF ./misc/cronjobs/longoverdue.pl -l 90=2 -v --skip-category STAFF You should see the items checked out to ADULT and CHILD set as lost, but STAFF will not be processed. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jweaver@bywatersolutions.co | |m, | |kyle@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Zeno Tajoli <z.tajoli@cineca.it> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |z.tajoli@cineca.it Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Zeno Tajoli <z.tajoli@cineca.it> changed: What |Removed |Added ---------------------------------------------------------------------------- CC|z.tajoli@cineca.it | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #42125|0 |1 is obsolete| | --- Comment #3 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 42614 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=42614&action=edit [SIGNED-OFF] Bug 14292: Add patron category restrictions to longoverdue.pl Add command line options --category and --skip-category Convert usage() to pod2usage. (This was previous FIXME) http://bugs.koha-community.org/show_bug.cgi?id=14292 Signed-off-by: hbraum@nekls.org -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #4 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Comment on attachment 42614 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=42614 [SIGNED-OFF] Bug 14292: Add patron category restrictions to longoverdue.pl Review of attachment 42614: --> (http://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html&bug=14292&attachment=42614) ----------------------------------------------------------------- ::: misc/cronjobs/longoverdue.pl @@ +52,5 @@
+GetOptions( + 'lost=s%' => \$lost, + 'c|charge=s' => \$charge, + 'confirm' => \$confirm, + 'verbose' => \$verbose,
Doc says v|verbose @@ +56,5 @@
+ 'verbose' => \$verbose, + 'quiet' => \$quiet, + 'maxdays=s' => \$endrange, + 'mark-returned' => \$mark_returned, + 'help' => \$help,
Doc says h|help @@ +77,5 @@
+ + longoverdue.pl [ --help | -h | --man ] + longoverdue.pl --lost | -l DAYS=LOST_CODE [ --charge | -c CHARGE_CODE ] [ --verbose | -v ] [ --quiet ] + [ --maxdays MAX_DAYS ] [ --mark-returned ] [ --category BORROWER_CATEGOERY ] ... + [ --skip-category BORROWER_CATEGOERY ] ... [ --commit ]
Typo 'CATEGOERY' @@ +141,5 @@
+=back + +All 'category' options will be applied before any 'skip-category' options, meaning that the only categories available to skip +are those which have already been specified on the command line.
Is this really useful? I would say --category and --skip-category could be mutually exclusive. That would simplify the related code. But it seems to work, so keep it if you think it can be useful. @@ +188,1 @@
die "ERROR: No --lost (-l) option defined";
This won't work, pod2usage will exist before the die statement. You should use something like: pod2usage({ -exitval => 1, -msg => q|ERROR: No --lost (-l) option defined|, }); @@ +224,5 @@
}
+# The following two functions can and should replaced by a call to +# Koha::Database. +sub borrower_categories_sth {
This can be avoided, we don't need a subroutine to prepare the query :) @@ +230,5 @@
+ return C4::Context->dbh->prepare($query); +} + +sub defined_borrower_categories { + my $sth = borrower_categories_sth();
Actually I think both sub could be replace with: my $dbh = C4::Context->dbh; return map { $_->[0] } @{ $dbh->selectall_arrayref(q|SELECT categorycode FROM categories|) }; @@ +273,4 @@
#FIXME - Should add a 'system' user and get suitable userenv for it for logging, etc.
my $count; +# my @ranges = map {
I would simply remove it :) @@ +294,5 @@
$sth_items->execute($startrange, $endrange, $lostvalue); $count=0; + ITEM: while (my $row=$sth_items->fetchrow_hashref) { + if( $filter_borrower_categories ) { + my $category = uc Koha::Database->new()->schema->resultset('Borrower')->find( $row->{borrowernumber} )->get_column('categorycode');
Why don't you use Koha::Borrowers? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA CC| |jonathan.druart@bugs.koha-c | |ommunity.org -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Heather Braum <hbraum@nekls.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |hbraum@nekls.org -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #5 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 42892 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=42892&action=edit Bug 14292: QA Follow-up -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #6 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Barton Chittenden from comment #5)
Created attachment 42892 [details] [review] Bug 14292: QA Follow-up
In this case it is always good to explain what does the follow-up. Either in a comment or, better, in the commit message. Should I suppose all my comments have been taken into account in it? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #7 from Barton Chittenden <barton@bywatersolutions.com> --- (In reply to Jonathan Druart from comment #4)
Comment on attachment 42614 [details] [review] [SIGNED-OFF] Bug 14292: Add patron category restrictions to longoverdue.pl
Review of attachment 42614 [details] [review]: -----------------------------------------------------------------
::: misc/cronjobs/longoverdue.pl @@ +52,5 @@
+GetOptions( + 'lost=s%' => \$lost, + 'c|charge=s' => \$charge, + 'confirm' => \$confirm, + 'verbose' => \$verbose,
Doc says v|verbose
@@ +56,5 @@
+ 'verbose' => \$verbose, + 'quiet' => \$quiet, + 'maxdays=s' => \$endrange, + 'mark-returned' => \$mark_returned, + 'help' => \$help,
Doc says h|help
@@ +77,5 @@
+ + longoverdue.pl [ --help | -h | --man ] + longoverdue.pl --lost | -l DAYS=LOST_CODE [ --charge | -c CHARGE_CODE ] [ --verbose | -v ] [ --quiet ] + [ --maxdays MAX_DAYS ] [ --mark-returned ] [ --category BORROWER_CATEGOERY ] ... + [ --skip-category BORROWER_CATEGOERY ] ... [ --commit ]
Typo 'CATEGOERY'
Fixed v|verbose and h|help options, as well as 'BORROWER_CATEGOERY' typo. I left the --category and --skip-category options as-is. I don't have a good reason to keep them, but they're not hurting anything either; we can re-visit if they cause confusion. Changed 'die' to
pod2usage({ -exitval => 1, -msg => q|ERROR: No --lost (-l) option defined|, });
Removed borrower_categories_sth in favor of my $dbh = C4::Context->dbh; my @categories = map { uc $_->[0] } @{ $dbh->selectall_arrayref(q|SELECT categorycode FROM categories|) };
@@ +273,4 @@
#FIXME - Should add a 'system' user and get suitable userenv for it for logging, etc.
my $count; +# my @ranges = map {
I would simply remove it :)
I wasn't clear about this comment, but I removed the #FIXME comment and the # my @ranges = map { statement, both of which seemed useless.
@@ +294,5 @@
$sth_items->execute($startrange, $endrange, $lostvalue); $count=0; + ITEM: while (my $row=$sth_items->fetchrow_hashref) { + if( $filter_borrower_categories ) { + my $category = uc Koha::Database->new()->schema->resultset('Borrower')->find( $row->{borrowernumber} )->get_column('categorycode');
Why don't you use Koha::Borrowers?
Done. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #8 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- IMO the TODO about the category handling should be addressed in this patch set. I let the needs QA status if another QAer think it can go as it. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #42614|0 |1 is obsolete| | --- Comment #9 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 43304 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43304&action=edit Bug 14292: Add patron category restrictions to longoverdue.pl Add command line options --category and --skip-category Convert usage() to pod2usage. (This was previous FIXME) http://bugs.koha-community.org/show_bug.cgi?id=14292 Signed-off-by: hbraum@nekls.org -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #42892|0 |1 is obsolete| | --- Comment #10 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 43305 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43305&action=edit Bug 14292: QA Follow-up Make borrower category handling more user friendly: Make --category and --skip-category mutally exclusive Check that categories specified by --category and --skip-category exist in categories table. Add --list-categories opttion to show available borrower categories. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #11 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43336 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43336&action=edit Bug 14292: QA fixes - wording and trailing whitespaces -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #12 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43337 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43337&action=edit Bug 14292: Simplify the category list Basically we have 3 lists of categories: 1/ The full one, in the DB 2/ The one we want and list with --category 3/ The one we don't want and list with --skip-category The list of categories to process is: * 1 if none --category or --skip-category options are provided * 2 if --category is provided * 1 - 3 if --skip-category is provided -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #13 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Barton, I am sorry but I think there was a misunderstanding. The idea was not to add more complexity but simplify the --category and --skip-category options. Could you please have a look at the last patch and, if you agree with this change, add your signoff on it? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #14 from Barton Chittenden <barton@bywatersolutions.com> --- (In reply to Jonathan Druart from comment #13)
Barton, I am sorry but I think there was a misunderstanding. The idea was not to add more complexity but simplify the --category and --skip-category options. Could you please have a look at the last patch and, if you agree with this change, add your signoff on it?
I eyeballed it; it looks good. I'll run a quick test and sign off. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Needs Signoff --- Comment #15 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Barton, Ok, waiting for your signoff :) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #16 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 43439 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43439&action=edit bug 14292: Make --category and --skip-category case insensitive -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off --- Comment #17 from Barton Chittenden <barton@bywatersolutions.com> --- Made small tweak: --category and --skip-category are now case insensitive. Tested and Signed off. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #18 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- No it doesn't, the script explodes! FAIL misc/cronjobs/longoverdue.pl FAIL valid "my" variable $borrower_category masks earlier declaration in same scope "my" variable $skip_borrower_category masks earlier declaration in same scope -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #43304|0 |1 is obsolete| | Attachment #43305|0 |1 is obsolete| | Attachment #43336|0 |1 is obsolete| | Attachment #43337|0 |1 is obsolete| | Attachment #43439|0 |1 is obsolete| | --- Comment #19 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43489 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43489&action=edit Bug 14292: Add patron category restrictions to longoverdue.pl Add command line options --category and --skip-category Convert usage() to pod2usage. (This was previous FIXME) http://bugs.koha-community.org/show_bug.cgi?id=14292 Signed-off-by: hbraum@nekls.org Signed-off-by: Barton Chittenden <barton@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #20 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43490 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43490&action=edit Bug 14292: QA Follow-up Make borrower category handling more user friendly: Make --category and --skip-category mutally exclusive Check that categories specified by --category and --skip-category exist in categories table. Add --list-categories opttion to show available borrower categories. Signed-off-by: Barton Chittenden <barton@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #21 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43491 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43491&action=edit Bug 14292: QA fixes - wording and trailing whitespaces Signed-off-by: Barton Chittenden <barton@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #22 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43492 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43492&action=edit Bug 14292: Simplify the category list Basically we have 3 lists of categories: 1/ The full one, in the DB 2/ The one we want and list with --category 3/ The one we don't want and list with --skip-category The list of categories to process is: * 1 if none --category or --skip-category options are provided * 2 if --category is provided * 1 - 3 if --skip-category is provided Signed-off-by: Barton Chittenden <barton@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #23 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43493 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43493&action=edit bug 14292: Make --category and --skip-category case insensitive Signed-off-by: Barton Chittenden <barton@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #24 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 43494 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=43494&action=edit Bug 14292: (follow-up) Make --category and --skip-category case insensitive "my" variable $borrower_category masks earlier declaration in same scope "my" variable $skip_borrower_category masks earlier declaration in same scope Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #25 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Jonathan Druart from comment #18)
No it doesn't, the script explodes!
FAIL misc/cronjobs/longoverdue.pl FAIL valid "my" variable $borrower_category masks earlier declaration in same scope "my" variable $skip_borrower_category masks earlier declaration in same scope
I have submitted a follow-up, marked as passed QA. (Have a look at the QA script :)) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Barton Chittenden <barton@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #43489|0 |1 is obsolete| | Attachment #43490|0 |1 is obsolete| | Attachment #43491|0 |1 is obsolete| | Attachment #43492|0 |1 is obsolete| | Attachment #43493|0 |1 is obsolete| | Attachment #43494|0 |1 is obsolete| | --- Comment #26 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 45293 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45293&action=edit Bug 14292: Add patron category restrictions to longoverdue.pl Squashed prevoius patch set. Add command line options --category and --skip-category Convert usage() to pod2usage. (This was previous FIXME) Make borrower category handling more user friendly: Make --category and --skip-category mutally exclusive Check that categories specified by --category and --skip-category exist in categories table. Add --list-categories opttion to show available borrower categories. http://bugs.koha-community.org/show_bug.cgi?id=14292 QA Follow-up QA fixes - wording and trailing whitespaces Simplify the category list Basically we have 3 lists of categories: 1/ The full one, in the DB 2/ The one we want and list with --category 3/ The one we don't want and list with --skip-category The list of categories to process is: * 1 if none --category or --skip-category options are provided * 2 if --category is provided * 1 - 3 if --skip-category is provided (follow-up) Make --category and --skip-category case insensitive "my" variable $borrower_category masks earlier declaration in same scope "my" variable $skip_borrower_category masks earlier declaration in same scope Signed-off-by: hbraum@nekls.org Signed-off-by: Barton Chittenden <barton@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 --- Comment #27 from Barton Chittenden <barton@bywatersolutions.com> --- Created attachment 45296 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45296&action=edit Bug 14292: [Alternate for 3.18] Add patron category restrictions to longoverdue.pl This is the same patch set, rebased on 3.18.x Add command line options --category and --skip-category Convert usage() to pod2usage. (This was previous FIXME) Make borrower category handling more user friendly: Make --category and --skip-category mutally exclusive Check that categories specified by --category and --skip-category exist in categories table. Add --list-categories opttion to show available borrower categories. http://bugs.koha-community.org/show_bug.cgi?id=14292 QA Follow-up QA fixes - wording and trailing whitespaces Simplify the category list Basically we have 3 lists of categories: 1/ The full one, in the DB 2/ The one we want and list with --category 3/ The one we don't want and list with --skip-category The list of categories to process is: * 1 if none --category or --skip-category options are provided * 2 if --category is provided * 1 - 3 if --skip-category is provided (follow-up) Make --category and --skip-category case insensitive "my" variable $borrower_category masks earlier declaration in same scope "my" variable $skip_borrower_category masks earlier declaration in same scope Signed-off-by: hbraum@nekls.org Signed-off-by: Barton Chittenden <barton@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14292 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #28 from Kyle M Hall <kyle@bywatersolutions.com> --- Pushed to master, thanks Barton! -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org