From d2d937fc9bb4bdd886c12964c4a21b324626528b Mon Sep 17 00:00:00 2001 From: Katrin Fischer Date: Sun, 22 Apr 2018 22:00:17 +0000 Subject: [PATCH] Bug 19171: Attempt to make "no holds possible" messages less confusing At the moment, when no holds are possible, the OPAC reads something like: Sorry, none of these items can be placed on hold. No items available. This is confusing to the patrons, because the records have items, but they are not showing. The record also may have available items, they are just not permitted to place holds on them. Changes: - Only display the first message, when somoene tried unsuccessfully to place holds on multiple records. - Change first message to: Sorry, none of these titles can be placed on hold. - Change the second message to read: No items available to be placed on hold. - Remove around Sorry for better translatability. To test: - Try to place a hold on single record, where no hold is possible. - Try to place a hold on a single record, where a hold is possible. - Try to place holds on multiple records where no hold is possible. - Try to place holds on multiple records where at least one hold is possible. Verify the screen messages make sense in all cases. Signed-off-by: Owen Leonard Fixed stray during signoff. Signed-off-by: Marcel de Rooy For consistency with staff, I renamed multi_holds to multi_hold. Signed-off-by: Jonathan Druart --- koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt | 8 ++++---- opac/opac-reserve.pl | 4 ++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt index 0f2f4eb697..e35c240c16 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt @@ -22,7 +22,7 @@
[% IF ( message ) %]
-

Sorry, you cannot place holds.

+

Sorry, you cannot place holds.

    [% IF ( GNA ) %]
  • @@ -106,9 +106,9 @@ [% ELSE %] - [% IF ( none_available ) %] + [% IF ( none_available && multi_hold ) %]
    - Sorry, none of these items can be placed on hold. + Sorry, none of these titles can be placed on hold.
    [% END %]
@@ -174,7 +174,7 @@
You have already requested this title.
[% ELSE %] [% UNLESS ( bibitemloo.bib_available ) %] -
No available items.
+
There are no items that can be placed on hold.
[% ELSE %] [% IF ( bibitemloo.already_patron_possession ) %]
This title cannot be requested because it's already in your possession.
diff --git a/opac/opac-reserve.pl b/opac/opac-reserve.pl index 2be6991530..4a0dbb9837 100755 --- a/opac/opac-reserve.pl +++ b/opac/opac-reserve.pl @@ -623,6 +623,10 @@ if ( $numBibsAvailable == 0 || $anyholdable == 0) { $template->param( none_available => 1 ); } +if (scalar @biblionumbers > 1) { + $template->param( multi_hold => 1); +} + my $show_notes=C4::Context->preference('OpacHoldNotes'); $template->param(OpacHoldNotes=>$show_notes); -- 2.39.5