Bugzilla – Attachment 149699 Details for
Bug 33271
Show information about patron's guarantees charges on patron details page
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33271: Add collective owing message to moremember page
Bug-33271-Add-collective-owing-message-to-morememb.patch (text/plain), 2.96 KB, created by
ByWater Sandboxes
on 2023-04-14 17:30:54 UTC
(
hide
)
Description:
Bug 33271: Add collective owing message to moremember page
Filename:
MIME Type:
Creator:
ByWater Sandboxes
Created:
2023-04-14 17:30:54 UTC
Size:
2.96 KB
patch
obsolete
>From bf9f38074db43676860f3bb6bcfc0472c4cefb54 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Wed, 12 Apr 2023 17:29:43 +0000 >Subject: [PATCH] Bug 33271: Add collective owing message to moremember page > >To test: >1. Turn on NoIssuesChargeGuarantorsWithGuarantees and set the amount to 5. >2. Create a guarantor/guarantee relationship. >3. Add a manual invoice to the guarantor that is larger than 5.00. >4. Notice the message on that circulation ( check out tab ) page. " Charges: Patron's guarantors and their other guarantees collectively owe X. Checkouts are BLOCKED because fine balance is OVER THE LIMIT. " >5. Look at the moremember ( details ) page. The same message does not appear. >6. Apply patch, restart_all >7. Try step 5 again, the message should now appear. > >Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> >--- > .../prog/en/includes/patron_messages.inc | 2 +- > members/moremember.pl | 13 +++++++++++++ > 2 files changed, 14 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/patron_messages.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/patron_messages.inc >index 19ba6cee80..e52cc6e7b3 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/patron_messages.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/patron_messages.inc >@@ -76,7 +76,7 @@ > [% END %] > <a class="btn btn-xs btn-default" href="#reldebarments" onclick="$('#debarments-tab-link').click()"><i class="fa fa-ban"></i> View restrictions</a> > >- [% IF (noissues && CAN_user_circulate_force_checkout) %] >+ [% IF (noissues && CAN_user_circulate_force_checkout && !moremember) %] > <span class="override_debarment"> > <a href="/cgi-bin/koha/circ/circulation.pl?forceallow=1&borrowernumber=[% patron.borrowernumber | uri %]" class="btn btn-xs btn-default">Override restriction temporarily</a> > </span> >diff --git a/members/moremember.pl b/members/moremember.pl >index bf422d7749..5a3bb53f70 100755 >--- a/members/moremember.pl >+++ b/members/moremember.pl >@@ -246,6 +246,19 @@ if( ( my $owing = $account->non_issues_charges ) > 0 ) { > ); > } > >+# Check the debt of this patrons guarantors *and* the guarantees of those guarantors >+my $no_issues_charge_guarantors = C4::Context->preference("NoIssuesChargeGuarantorsWithGuarantees"); >+if ( $no_issues_charge_guarantors ) { >+ my $guarantors_non_issues_charges = $patron->relationships_debt({ include_guarantors => 1, only_this_guarantor => 0, include_this_patron => 1 }); >+ >+ if ( $guarantors_non_issues_charges > $no_issues_charge_guarantors ) { >+ $template->param( >+ noissues => 1, >+ charges_guarantors_guarantees => $guarantors_non_issues_charges >+ ); >+ } >+} >+ > # if the expiry date is before today ie they have expired > if ( $patron->is_expired ) { > #borrowercard expired, no issues >-- >2.30.2
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 33271
:
149571
|
149699
|
152892