Bug 24776: Remove Borrowers.HasOverdues call

Borrowers Template Toolkit plugin contains method HasOverdues that can be directly called from Koha::Patron object.

Test plan :
1) Go to circulation page of a patron with overdues
2) Click on print button
3) You see "Print overdues"
4) Go to circulation page of a patron without overdues
5) Click on print button
6) You don't see "Print overdues"

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
This commit is contained in:
Fridolin Somers 2020-03-02 17:18:34 +03:00 committed by Martin Renvoize
parent f4f841fd8c
commit e0483bd6e2
Signed by: martin.renvoize
GPG key ID: 422B469130441A0F

View file

@ -1,6 +1,5 @@
[% INCLUDE 'blocking_errors.inc' %]
[% USE Koha %]
[% USE Borrowers %]
[% USE Branches %]
[% USE Categories %]
[% USE AuthorisedValues %]
@ -25,7 +24,7 @@
<li><a id="printsummary" href="#">Print summary</a></li>
<li><a id="printslip" href="#">Print slip</a></li>
<li><a id="printquickslip" href="#">Print quick slip</a></li>
[% IF Borrowers.HasOverdues( patron.borrowernumber ) %]
[% IF patron.has_overdues %]
<li><a id="print_overdues" href="#">Print overdues</a></li>
[% END %]
</ul>