From f76b032bb6568a7c07b795a809ceca8d9c2dc3bc Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 9 Feb 2021 16:01:59 +0100 Subject: [PATCH] Bug 27645: Prevent "is on hold" warning to be displayed twice During a batch checkout we display the "item is on hold" message depending on different conditions. However it can happen the message is displayed twice. If the checkout is not impossible then we see: This item is on hold for another patron. This item is on hold for another patron. The hold will be overridden, but not cancelled. We should only display the second one. Test plan: With a default ktd setup you can simply place an item on hold and use the batch checkout tool to check it out Signed-off-by: Lucas Gass Signed-off-by: Julian Maurice --- .../en/modules/circ/circulation_batch_checkouts.tt | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt index 59495fe2e7..6793b95c91 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt @@ -147,9 +147,6 @@ [% IF checkout_info.RESERVE_WAITING %]
  • This item is waiting for another patron.
  • [% END %] - [% IF checkout_info.RESERVED %] -
  • This item is on hold for another patron.
  • - [% END %] [% IF checkout_info.ISSUED_TO_ANOTHER %]
  • This item is checked out to another patron. [% IF CAN_user_circulate_force_checkout %] @@ -190,10 +187,10 @@ [% END %] - [% IF NOT checkout_info.IMPOSSIBLE && ( CAN_user_circulate_force_checkout or checkout_info.HIGHHOLDS ) %] - [% IF checkout_info.RESERVED || checkout_info.RESERVE_WAITING %] -
  • This item is on hold for another patron. The hold will be overridden, but not cancelled.
  • - [% END %] + [% IF NOT checkout_info.IMPOSSIBLE && ( CAN_user_circulate_force_checkout || checkout_info.HIGHHOLDS ) && ( checkout_info.RESERVED || checkout_info.RESERVE_WAITING ) %] +
  • This item is on hold for another patron. The hold will be overridden, but not cancelled.
  • + [% ELSIF checkout_info.RESERVED %] +
  • This item is on hold for another patron.
  • [% END %] [% IF checkout_info.PREVISSUE %] -- 2.20.1