Bugzilla – Attachment 130571 Details for
Bug 30099
Error when accessing circulation.pl without patron parameter
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30099: Fix error when accessing circulation.pl without patron parameter
Bug-30099-Fix-error-when-accessing-circulationpl-w.patch (text/plain), 1.98 KB, created by
Fridolin Somers
on 2022-02-14 20:40:32 UTC
(
hide
)
Description:
Bug 30099: Fix error when accessing circulation.pl without patron parameter
Filename:
MIME Type:
Creator:
Fridolin Somers
Created:
2022-02-14 20:40:32 UTC
Size:
1.98 KB
patch
obsolete
>From dd49475a2e5cd871b4a5eaf60a0151976f8b85c4 Mon Sep 17 00:00:00 2001 >From: Fridolin Somers <fridolin.somers@biblibre.com> >Date: Mon, 14 Feb 2022 10:35:53 -1000 >Subject: [PATCH] Bug 30099: Fix error when accessing circulation.pl without > patron parameter > >If I access circulation.pl directly, with no patron cardnumber or borrowernumber submitted, I get an error: >Can't call method "messages" on an undefined value at /kohadevbox/koha/circ/circulation.pl line 525 > >This is caused by Bug 29230 which calls $patron outside a >"if ($aptron)". > >Test plan : >1) In staff interface, click in 'check out' search box >2) Hit enter (without a search text) >=> Without patch you get an error >=> With patch you see a blank page /cgi-bin/koha/circ/circulation.pl >--- > circ/circulation.pl | 21 +++++++++++---------- > 1 file changed, 11 insertions(+), 10 deletions(-) > >diff --git a/circ/circulation.pl b/circ/circulation.pl >index b98f120503..1471f3d160 100755 >--- a/circ/circulation.pl >+++ b/circ/circulation.pl >@@ -520,16 +520,18 @@ if ( $patron ) { > forceallow => $force_allow_issue, > ); > } >-} > >-my $patron_messages = $patron->messages->search( >- {}, >- { >- join => 'manager', >- '+select' => ['manager.surname', 'manager.firstname' ], >- '+as' => ['manager_surname', 'manager_firstname'], >- } >-); >+ my $patron_messages = $patron->messages->search( >+ {}, >+ { >+ join => 'manager', >+ '+select' => ['manager.surname', 'manager.firstname' ], >+ '+as' => ['manager_surname', 'manager_firstname'], >+ } >+ ); >+ $template->param( patron_messages => $patron_messages ); >+ >+} > > my $fast_cataloging = 0; > if ( Koha::BiblioFrameworks->find('FA') ) { >@@ -576,7 +578,6 @@ if ($restoreduedatespec || $stickyduedate) { > } > > $template->param( >- patron_messages => $patron_messages, > borrowernumber => $borrowernumber, > branch => $branch, > was_renewed => scalar $query->param('was_renewed') ? 1 : 0, >-- >2.35.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 30099
:
130571
|
130573
|
130591