Bugzilla – Attachment 123773 Details for
Bug 28667
Check damaged item can be reserved in OPAC detail pages
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28667: Check damaged item can be reserved in OPAC detail pages
Bug-28667-Check-damaged-item-can-be-reserved-in-OP.patch (text/plain), 2.49 KB, created by
Fridolin Somers
on 2021-08-11 09:25:30 UTC
(
hide
)
Description:
Bug 28667: Check damaged item can be reserved in OPAC detail pages
Filename:
MIME Type:
Creator:
Fridolin Somers
Created:
2021-08-11 09:25:30 UTC
Size:
2.49 KB
patch
obsolete
>From fd02c18490437e152e9816ecad2da277bb3b0fc3 Mon Sep 17 00:00:00 2001 >From: Fridolin Somers <fridolin.somers@biblibre.com> >Date: Mon, 5 Jul 2021 21:44:21 -1000 >Subject: [PATCH] Bug 28667: Check damaged item can be reserved in OPAC detail > pages > >In OPAC detail pages, damaged items must impact the "place hold" link. >This behavior depends on preference AllowHoldsOnDamagedItems. > >Test plan : >1) Create a record with one damaged item >2) Set AllowHoldsOnDamagedItems to 'Allow' >3) Go to OPAC record detail page : opac-detail.pl >4) Check you see "Place hold" link >5) Set AllowHoldsOnDamagedItems to 'Don't allow' >6) Refresh page >7) Check you don't see "Place hold" link >Same tests 2 to 7 for pages opac-ISBDdetail.pl and opac-MARCdetail.pl >--- > opac/opac-ISBDdetail.pl | 1 + > opac/opac-MARCdetail.pl | 1 + > opac/opac-detail.pl | 1 + > 3 files changed, 3 insertions(+) > >diff --git a/opac/opac-ISBDdetail.pl b/opac/opac-ISBDdetail.pl >index 567caf4118..5408cc3a0f 100755 >--- a/opac/opac-ISBDdetail.pl >+++ b/opac/opac-ISBDdetail.pl >@@ -178,6 +178,7 @@ while ( my $item = $items->next ) { > if $norequests > && !$item->withdrawn > && !$item->itemlost >+ && ( !$item->damaged || C4::Context->preference('AllowHoldsOnDamagedItems') ) > && ($item->notforloan < 0 || not $item->notforloan ) > && !Koha::ItemTypes->find($item->effective_itemtype)->notforloan > && $item->itemnumber; >diff --git a/opac/opac-MARCdetail.pl b/opac/opac-MARCdetail.pl >index 69578be6aa..2fb3915098 100755 >--- a/opac/opac-MARCdetail.pl >+++ b/opac/opac-MARCdetail.pl >@@ -152,6 +152,7 @@ while ( my $item = $items->next ) { > if $norequests > && !$item->withdrawn > && !$item->itemlost >+ && ( !$item->damaged || C4::Context->preference('AllowHoldsOnDamagedItems') ) > && ($item->notforloan < 0 || not $item->notforloan ) > && !Koha::ItemTypes->find($item->effective_itemtype)->notforloan > && $item->itemnumber; >diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl >index cbb216e291..32790bb509 100755 >--- a/opac/opac-detail.pl >+++ b/opac/opac-detail.pl >@@ -742,6 +742,7 @@ if ( not $viewallitems and @items > $max_items_to_display ) { > if $norequests > && !$itm->{'withdrawn'} > && !$itm->{'itemlost'} >+ && ( !$itm->{'damaged'} || C4::Context->preference('AllowHoldsOnDamagedItems') ) > && ($itm->{'itemnotforloan'}<0 || not $itm->{'itemnotforloan'}) > && !$itemtypes->{$itm->{'itype'}}->{notforloan} > && $itm->{'itemnumber'}; >-- >2.32.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 28667
:
122599
|
123773
|
123805
|
124981
|
124982
|
124983