Bugzilla – Attachment 161773 Details for
Bug 34077
writeoff_debts without --confirm doesn't show which accountline records it would have been written off
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34077: Only print verbose output when asked for
Bug-34077-Only-print-verbose-output-when-asked-for.patch (text/plain), 1.57 KB, created by
Martin Renvoize (ashimema)
on 2024-02-06 12:16:19 UTC
(
hide
)
Description:
Bug 34077: Only print verbose output when asked for
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2024-02-06 12:16:19 UTC
Size:
1.57 KB
patch
obsolete
>From 57b9cf6b3cb6011ff84050da67ce6113b4d6d508 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Tue, 6 Feb 2024 12:14:28 +0000 >Subject: [PATCH] Bug 34077: Only print verbose output when asked for > >This patch updates the logic such that we only trigger verbose when >verbose is explicitly asked for. >--- > misc/cronjobs/writeoff_debts.pl | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > >diff --git a/misc/cronjobs/writeoff_debts.pl b/misc/cronjobs/writeoff_debts.pl >index 858c5a2324e..84543a8f6fd 100755 >--- a/misc/cronjobs/writeoff_debts.pl >+++ b/misc/cronjobs/writeoff_debts.pl >@@ -24,7 +24,7 @@ GetOptions( > ); > @type = split( /,/, join( ',', @type ) ); > >-pod2usage(1) if ( $help || !$file && !@type && !$before && !$after ); >+pod2usage(1) if ( $help || !$file && !@type && !$before && !$after && !@category_code ); > > my $where = { 'amountoutstanding' => { '>' => 0 } }; > my $attr = {}; >@@ -67,7 +67,6 @@ if (@category_code) { > > my $lines = Koha::Account::Lines->search( $where, $attr ); > >-$verbose //= !$confirm; > if ( $verbose ) { > print "Attempting to write off " . $lines->count . " debts" if $confirm; > print "With --confirm we would write off " . $lines->count . " debts" if !$confirm; >@@ -202,8 +201,7 @@ This flag set the script to output logging for the actions it will perform. > =item B<-c|--confirm> > > This flag must be provided in order for the script to actually >-writeoff debts. If it is not supplied, the script will >-only report on the accountline records it would have been written off. >+writeoff debts. > > =back > >-- >2.43.0
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 34077
:
157230
|
159598
|
159987
|
161772
|
161773
|
161774
|
162234
|
162235
|
167403
|
167404