Bugzilla – Attachment 180784 Details for
Bug 39603
OPAC advanced search display or ITEMTYPECAT is wrong if other authorised values have the same code
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 39603: Make sure authorised value category is ITEMTYPECAT
Bug-39603-Make-sure-authorised-value-category-is-I.patch (text/plain), 1.73 KB, created by
Lucas Gass (lukeg)
on 2025-04-10 15:48:50 UTC
(
hide
)
Description:
Bug 39603: Make sure authorised value category is ITEMTYPECAT
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2025-04-10 15:48:50 UTC
Size:
1.73 KB
patch
obsolete
>From 135121fae67d670481311fd7ebacdf3b41e87808 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Thu, 10 Apr 2025 15:47:28 +0000 >Subject: [PATCH] Bug 39603: Make sure authorised value category is ITEMTYPECAT > >To test: >1. Add some AVs for ITEMTYPECAT and set some of your item types to be in that Search category. I made one called OTHER >2. Go to the OPAC advanced search page, the item types should be correctly displaying under ITEMTYPECAT with the correct description from ITEMTYPECAT. >3. Create a new AV called OTHER in a different category like 'ERM_AGREEMENT_CLOSURE_REASON'. Make the description something different like 'Wrong description'. >4. Now go back to the OPAC advanced search. >5. Notice your OTHER option now reads 'Wrong description'. >6. APPLY PATCH and restart_all >7. Try again, the OPAC descriptions should now be correct. >--- > C4/Koha.pm | 2 ++ > 1 file changed, 2 insertions(+) > >diff --git a/C4/Koha.pm b/C4/Koha.pm >index d97172e333f..b06a4d6078f 100644 >--- a/C4/Koha.pm >+++ b/C4/Koha.pm >@@ -101,6 +101,7 @@ sub GetItemTypesCategorized { > FROM itemtypes > LEFT JOIN authorised_values ON searchcategory = authorised_value > WHERE searchcategory > '' and hideinopac=1 >+ AND category = 'ITEMTYPECAT' > UNION > SELECT DISTINCT searchcategory AS `itemtype`, > COALESCE(authorised_values.lib_opac,authorised_values.lib) AS description, >@@ -109,6 +110,7 @@ sub GetItemTypesCategorized { > FROM itemtypes > LEFT JOIN authorised_values ON searchcategory = authorised_value > WHERE searchcategory > '' and hideinopac=0 >+ AND category = 'ITEMTYPECAT' > |; > return ( $dbh->selectall_hashref( $query, 'itemtype' ) ); > } >-- >2.39.5
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 39603
:
180784
|
180801