Bugzilla – Attachment 172277 Details for
Bug 17976
TT syntax for notices - Add an equivalence for items.fine
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 17976: Update test to include fines
Bug-17976-Update-test-to-include-fines.patch (text/plain), 2.09 KB, created by
Martin Renvoize (ashimema)
on 2024-10-01 14:57:27 UTC
(
hide
)
Description:
Bug 17976: Update test to include fines
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2024-10-01 14:57:27 UTC
Size:
2.09 KB
patch
obsolete
>From a7d207d593896d13407dd8de75e3a8ea72b0acab Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Tue, 1 Oct 2024 15:53:11 +0100 >Subject: [PATCH] Bug 17976: Update test to include fines > >This patch updates the existing test to include checking the alternative >to items.fine syntax. > >We could use the account_lines relation, however that would include >other charges linked to the checkout, for example rental charges. > >I opt to add a new accessor to give us more options and refine to just >overdue fines. >--- > t/db_dependent/Letters/TemplateToolkit.t | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > >diff --git a/t/db_dependent/Letters/TemplateToolkit.t b/t/db_dependent/Letters/TemplateToolkit.t >index 1ac70733b14..35c836a97c4 100755 >--- a/t/db_dependent/Letters/TemplateToolkit.t >+++ b/t/db_dependent/Letters/TemplateToolkit.t >@@ -839,7 +839,7 @@ If you have registered a password with the library, and you have a renewal avail > > The following item(s) is/are currently overdue: > >-<item>"<<biblio.title>>" by <<biblio.author>>, <<items.itemcallnumber>>, Barcode: <<items.barcode>></item> >+<item>"<<biblio.title>>" by <<biblio.author>>, <<items.itemcallnumber>>, Barcode: <<items.barcode>>, Fine: <<items.fine>></item> > > <<items.content>> > >@@ -889,6 +889,7 @@ EOF > > # historic syntax > my $tt_template = <<EOF; >+[%- USE Price -%] > Dear [% borrower.firstname %] [% borrower.surname %], > > According to our current records, you have items that are overdue.Your library does not charge late fines, but please return or renew them at the branch below as soon as possible. >@@ -906,7 +907,7 @@ The following item(s) is/are currently overdue: > > [% FOREACH overdue IN overdues %] > [%~ SET item = overdue.item ~%] >-"[% item.biblio.title %]" by [% item.biblio.author %], [% item.itemcallnumber %], Barcode: [% item.barcode %] >+"[% item.biblio.title %]" by [% item.biblio.author %], [% item.itemcallnumber %], Barcode: [% item.barcode %], Fine: [% overdue.overdue_fines.total_outstanding | \$Price %] > [% END %] > [% FOREACH overdue IN overdues %] > [%~ SET item = overdue.item ~%] >-- >2.46.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 17976
:
172277
|
172278
|
172283
|
172304
|
172305
|
172306
|
172328
|
172329
|
172330
|
172331
|
174324