Bugzilla – Attachment 141346 Details for
Bug 22321
Make it possible to edit illrequests.borrowernumber
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 22321: Fix store() crash when modifying borrowernumber of a new ILL request
Bug-22321-Fix-store-crash-when-modifying-borrowern.patch (text/plain), 1.46 KB, created by
Martin Renvoize (ashimema)
on 2022-10-05 10:45:15 UTC
(
hide
)
Description:
Bug 22321: Fix store() crash when modifying borrowernumber of a new ILL request
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2022-10-05 10:45:15 UTC
Size:
1.46 KB
patch
obsolete
>From 02b3f759e771b371a49eb6fe4b788e5a79abff19 Mon Sep 17 00:00:00 2001 >From: Lari Taskula <lari.taskula@hypernova.fi> >Date: Tue, 22 Feb 2022 14:13:58 +0000 >Subject: [PATCH] Bug 22321: Fix store() crash when modifying borrowernumber of > a new ILL request > >To test: >1. prove t/db_dependent/Illrequests.t > >Signed-off-by: Magnus Enger <magnus@libriotech.no> >Tried to change the borrowernumber connected to an ILL request >and checked that the associated hold was updated to the new >patron as well. > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > Koha/Illrequest.pm | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/Koha/Illrequest.pm b/Koha/Illrequest.pm >index c60c1dcdf9..723b11843e 100644 >--- a/Koha/Illrequest.pm >+++ b/Koha/Illrequest.pm >@@ -1761,7 +1761,7 @@ sub store { > my %updated_columns = $self->_result->get_dirty_columns; > > my @holds; >- if( defined $updated_columns{'borrowernumber'} and >+ if( $self->in_storage and defined $updated_columns{'borrowernumber'} and > Koha::Patrons->find( $updated_columns{'borrowernumber'} ) ) > { > # borrowernumber has changed >@@ -1769,7 +1769,7 @@ sub store { > @holds = Koha::Holds->search( { > borrowernumber => $old_illreq->borrowernumber, > biblionumber => $self->biblio_id, >- } )->as_list; >+ } )->as_list if $old_illreq; > } > > my $ret = $self->SUPER::store; >-- >2.20.1
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 22321
:
130544
|
130545
|
130546
|
131012
|
131013
|
131055
|
131056
|
131057
|
131058
|
131059
|
138873
|
138874
|
138875
|
138876
|
138877
|
138878
|
141342
|
141343
|
141344
|
141345
| 141346 |
141347