Bug 33395: Patron search results - show number of overdues and checkouts when patrons...
authorDavid Nind <david@davidnind.com>
Sat, 23 Sep 2023 01:10:31 +0000 (01:10 +0000)
committerMatt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Tue, 17 Oct 2023 17:23:41 +0000 (17:23 +0000)
commita18d11c2f87159aedaf56b8988677db2f674071d
tree264467417dee60b9ad0eab3bdc95d2d8c8eaef3e
parent34b12abe98932cacaadf32ab4d70eb7e4d386cdd
Bug 33395: Patron search results - show number of overdues and checkouts when patrons have overdues

This fixes the display of patron search results, so that it shows
the number of checkouts when a patron has overdue items. For
example: 1 / 2

Bug 30063 changed the display to show only the number of overdue
items in bold and red, without the total number of items checked
out.

Test plan:
1. Check out two items to a patron - make one overdue (click the
   checkout setting options and then specify a due date a month
   ago).
2. Check out another item to another patron.
3. Search for patrons so that the two patrons you checked out
   items to are listed in the results.
4. Note the display for the 'Checkouts' column:
   4.1 For patrons without any checkouts: 0 / 0
   4.2 For the patron from step 2 with one checkout: 0 / 1
   4.3 For the patron from step 1 with one overdue and one
       checkout: 1 (in bold and red)
5. Apply the patch.
6. Refresh the page of results (step 3).
7. Note that for the patron from step 1, the display now shows:
   1 / 2 (with the 1 in bold and red).
8. Sign off! 8-)

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit c9ab718a39174d0a874fc8de8964b6f96b704f37)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 96c97fb95f6258a04deafd75fc96ba6182c47d27)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc