Bugzilla – Attachment 76099 Details for
Bug 19288
Holds placed on a specific item after a next available hold will show varied results
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 19288: Only display holds if next in queue or waiting
Bug-19288-Only-display-holds-if-next-in-queue-or-w.patch (text/plain), 1.52 KB, created by
Nick Clemens (kidclamp)
on 2018-06-15 13:14:09 UTC
(
hide
)
Description:
Bug 19288: Only display holds if next in queue or waiting
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2018-06-15 13:14:09 UTC
Size:
1.52 KB
patch
obsolete
>From 31c58cb54a157f953b5a9926a172cb89d2ebb821 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 15 Jun 2018 13:10:14 +0000 >Subject: [PATCH] Bug 19288: Only display holds if next in queue or waiting > >To test: > 1 - Place a title level hold on a biblio for a patron > 2 - View the details, the item(s) has no info about holds > 3 - Place an item level hold for an item on the same biblio for another patron > 4 - View the details page, note the item indicates it is held for the >second patron > 5 - Apply patch > 6 - Refresh details, the hold is not indicated > 7 - Set the item specific hold to be priority #1 > 8 - Refresh details, the hold should now be indicated > 9 - Confirm the hold >10 - Refresh details, the hold should show as waiting >--- > catalogue/detail.pl | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > >diff --git a/catalogue/detail.pl b/catalogue/detail.pl >index 86a0698..7c6bf47 100755 >--- a/catalogue/detail.pl >+++ b/catalogue/detail.pl >@@ -260,7 +260,8 @@ foreach my $item (@items) { > # checking for holds > my $item_object = Koha::Items->find( $item->{itemnumber} ); > my $holds = $item_object->current_holds; >- if ( my $first_hold = $holds->next ) { >+ my $first_hold = $holds->next; >+ if ( $first_hold && $first_hold->priority <= 1 ) { #we should only display if this hold is up next in the queue > my $patron = Koha::Patrons->find( $first_hold->borrowernumber ); > $item->{backgroundcolor} = 'reserved'; > $item->{reservedate} = $first_hold->reservedate; >-- >2.1.4
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 19288
:
76099
|
76100
|
89059
|
95898
|
100328
|
100632
|
100633