Bugzilla – Attachment 69835 Details for
Bug 19706
Item search: Unsupported format html
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 19706: Fix bad json formed when there are no CCODE values
Bug-19706-Fix-bad-json-formed-when-there-are-no-CC.patch (text/plain), 1.92 KB, created by
Josef Moravec
on 2017-12-17 07:31:56 UTC
(
hide
)
Description:
Bug 19706: Fix bad json formed when there are no CCODE values
Filename:
MIME Type:
Creator:
Josef Moravec
Created:
2017-12-17 07:31:56 UTC
Size:
1.92 KB
patch
obsolete
>From 732ecca52919858b8ccddaee88589ae7595c6f26 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Tue, 12 Dec 2017 11:15:34 +0000 >Subject: [PATCH] Bug 19706: Fix bad json formed when there are no CCODE values > >To test: >1 - Delete all ccode values in your system >2 - Load the item search page >3 - View the console and note a js error >4 - Try to perform an item search to screen >5 - Internal server error ("unsupported format 'html'" in logs) >6 - Apply patch >7 - Reload page >8 - Note js error is gone >9 - Perform search to screen, success! > >To test there is no regression: >1 - Have some values in CCODE authorised values >2 - Ensure collection drop down on item search displays correctly >3 - Ensure item search returns results ot screen with no js errors > >Signed-off-by Owen Leonard <oleonard@myacpl.org> > >Signed-off-by: David Bourgault <david.bourgault@inlibro.com> > >Signed-off-by: Josef Moravec <josef.moravec@gmail.com> >--- > koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt >index 5e02cc4..5b9edbe 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt >@@ -363,7 +363,11 @@ > { 'type': 'text' }, > { 'type': 'text' }, > { 'type': 'text' }, >- { 'type': 'select', 'values': [% ccodes.json %] }, >+ [% IF ccodes.size %] >+ { 'type': 'select', 'values': [% ccodes.json %] }, >+ [% ELSE %] >+ null, >+ [% END %] > { 'type': 'text' }, > { 'type': 'text' }, > { 'type': 'select', 'values': [% branches.json %] }, >-- >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 19706
:
69729
|
69745
|
69800
|
69831
|
69832
| 69835 |
69836