From 1ac50443001dd56c96808ea73d565ac20c540669 Mon Sep 17 00:00:00 2001 From: Josef Moravec Date: Thu, 12 Oct 2017 08:40:43 +0200 Subject: [PATCH] Bug 14919: (followup) Show accurate status in holds history This patch fixes the status showed in holds history table. The determination of status is following: 1. "hold.found is 'F'" - Fullfilled - the hold was fullfilled by checking the item to patron. If hold reaches this state, it can't changed status anymore, or be cancelled, that's why this goes first 2. "hold.cancellationdate is filled" - When the hold is cancelled, its eventually waiting or in transit status remains the same, only cancellation dat is filled, so this has to go second 3. "hold.found is 'W'" - Hold is waiting 4. "hold.found is 'T'" - Hold is in transit to target library Test plan: 0) Apply the patch 2) Read the status determination note in this commit message and confirm it makes sense 1) Have patron/patrons with at least one hold in every status 2) Go to holds history page and confirm it show the right status 3) Try to break the status determination ;) Signed-off-by: Katrin Fischer Signed-off-by: Kyle M Hall Signed-off-by: Jonathan Druart --- .../intranet-tmpl/prog/en/modules/members/holdshistory.tt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt index 1a370adc5a..169e75a28e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt @@ -108,12 +108,14 @@ [% hold.itemtype %] - [% IF hold.found == 'W' %] + [% IF hold.found == 'F' %] + Fulfilled + [% ELSIF hold.cancellationdate %] + Cancelled + [% ELSIF hold.found == 'W' %] Waiting [% ELSIF hold.found == 'T' %] In transit - [% ELSIF hold.cancellationdate %] - Cancelled [% ELSE %] In queue [% END %] -- 2.39.5