Bugzilla – Attachment 150184 Details for
Bug 33504
ILS-DI does not record renewer_id for renewals creating issue with renewal history view
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33504: Update patron_to_html to deal with null
Bug-33504-Update-patrontohtml-to-deal-with-null.patch (text/plain), 1.76 KB, created by
Magnus Enger
on 2023-04-25 11:00:59 UTC
(
hide
)
Description:
Bug 33504: Update patron_to_html to deal with null
Filename:
MIME Type:
Creator:
Magnus Enger
Created:
2023-04-25 11:00:59 UTC
Size:
1.76 KB
patch
obsolete
>From 96e1d3a3405e06c39f4bab785102253e91ba2110 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Wed, 12 Apr 2023 11:49:51 +0100 >Subject: [PATCH] Bug 33504: Update patron_to_html to deal with null > >In the patron_to_html function we were dealing explicitly with the case >where patron may be passed undefined, but forgetting that it may be >returned as 'null' from the api too. Changing from `( patron === >undefined )` to `( patron == null )` is the recommended approach for >detecting 'undefined or null' in javascript. > >Signed-off-by: Magnus Enger <magnus@libriotech.no> >Works as advertised. Martin's test plan from Bugzilla: > >To test. >1) Use ILS-DI to renew an checkout >2) View the circulation history for the item >3) Click the 'View' button next to the count of renewals >4) Note that the modal just stalls at 'Retrieving renewals' >5) Apply the patch >6) Now the 'retrieving renewals' message should list the renewals instead. > >Note that step 2 should be something like "Go to the "Circulation >history" of the patron. > >https://bugs.koha-community.org/show_bug.cgi?id=22504 >--- > koha-tmpl/intranet-tmpl/prog/en/includes/js-patron-format.inc | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/js-patron-format.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/js-patron-format.inc >index 5e125dbc29..3f8cb940ee 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/js-patron-format.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/js-patron-format.inc >@@ -9,7 +9,7 @@ > */ > window.$patron_to_html = function( patron, config ) { > >- if ( patron === undefined ) { >+ if ( patron == null ) { > return ''; // empty string for no patron > } > >-- >2.34.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 33504
:
149524
|
150184
|
150451