Bug 23427: Better sorting of previous checkouts
authorFridolin Somers <fridolin.somers@biblibre.com>
Mon, 5 Aug 2019 13:25:02 +0000 (15:25 +0200)
committerLucas Gass <lucas@bywatersolutions.com>
Mon, 16 Dec 2019 22:05:58 +0000 (22:05 +0000)
commit811cc852ac10f2562da77139709f276e4dfbb70a
tree65af6ece4805452bb72152cb42bf4fc8078650c5
parentb373be4ab31e701cdf4f699fa3898fa054098826
Bug 23427: Better sorting of previous checkouts

In patron circulation or details page, previous checkouts are displayed sorted by due date.
Many checkouts may have same due date so it would be better to sort on timestamp as second sort criteria, like todays's checkouts.

Test plan :
1) Create for a patron two issues with same due date and a few seconds between them
2) Create another issue with a different due date
3) Come back a day later
4) Set preference previousIssuesDefaultSortOrder = "latest to earliest"
5) Go to patron circulation page and check sort order is OK : sorted by "Due date" then "Cheked out on"
6) Go to patron details page and check sort order is OK : sorted by "Due date" then "Cheked out on"
7) Set preference previousIssuesDefaultSortOrder = "earliest to latest"
8) Go to patron circulation page and check sort order is OK : sorted by "Due date" then "Cheked out on"
9) Go to patron details page and check sort order is OK : sorted by "Due date" then "Cheked out on"

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit b4a6d79e4dbd6de90d453140f696cf8ba75a2159)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
svc/checkouts