Bugzilla – Attachment 96377 Details for
Bug 24175
Cannot cancel holds - wrong parameter passed for itemnumber
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 24175: Take advantage of Koha::Item->holds
Bug-24175-Take-advantage-of-KohaItem-holds.patch (text/plain), 1.11 KB, created by
Jonathan Druart
on 2019-12-17 13:58:46 UTC
(
hide
)
Description:
Bug 24175: Take advantage of Koha::Item->holds
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2019-12-17 13:58:46 UTC
Size:
1.11 KB
patch
obsolete
>From 7208788d0ee5a935607309ed95193d8b7947b5be Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Tue, 17 Dec 2019 14:23:16 +0100 >Subject: [PATCH] Bug 24175: Take advantage of Koha::Item->holds > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > C4/SIP/ILS/Transaction/Hold.pm | 10 +++------- > 1 file changed, 3 insertions(+), 7 deletions(-) > >diff --git a/C4/SIP/ILS/Transaction/Hold.pm b/C4/SIP/ILS/Transaction/Hold.pm >index 44c1beb1bd..e442787dc5 100644 >--- a/C4/SIP/ILS/Transaction/Hold.pm >+++ b/C4/SIP/ILS/Transaction/Hold.pm >@@ -86,14 +86,10 @@ sub drop_hold { > $self->ok(0); > return $self; > } >+ > my $item = Koha::Items->find({ barcode => $self->{item}->id }); >- my $holds = Koha::Holds->search( >- { >- biblionumber => $item->biblionumber, >- itemnumber => $item->itemnumber, >- borrowernumber => $patron->borrowernumber >- } >- ); >+ my $holds = $item->holds->search({ borrowernumber => $patron->borrowernumber }); >+ > return $self unless $holds->count; > > $holds->next->cancel; >-- >2.11.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 24175
:
95999
|
96000
|
96372
|
96375
|
96376
|
96377
|
96378
|
96527
|
96528
|
96529
|
96530
|
96534
|
96535
|
96536
|
96537
|
96680
|
96681