From 350cdb06ad80042daeab17c36f820cd3e2d3c67d Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Tue, 4 Feb 2020 14:16:26 +0000 Subject: [PATCH] Bug 22302: Make ITEMTYPECAT descriptions fallback to lib description if no opac description Signed-off-by: Andrew Fuerste-Henry Signed-off-by: Jonathan Druart Signed-off-by: Martin Renvoize Signed-off-by: Joy Nelson (cherry picked from commit b985cf5b88fa5e04e7b3dcca263e3c9ce4d0b27a) Signed-off-by: Lucas Gass (cherry picked from commit 2a6c77f6aaba704e90fa8bc7976696233816ad50) Signed-off-by: Hayley Mapley --- C4/Koha.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/C4/Koha.pm b/C4/Koha.pm index dd0a165a58..546cc6f8ae 100644 --- a/C4/Koha.pm +++ b/C4/Koha.pm @@ -102,7 +102,7 @@ sub GetItemTypesCategorized { SELECT itemtype, description, imageurl, hideinopac, 0 as 'iscat' FROM itemtypes WHERE ISNULL(searchcategory) or length(searchcategory) = 0 UNION SELECT DISTINCT searchcategory AS `itemtype`, - authorised_values.lib_opac AS description, + COALESCE(authorised_values.lib_opac,authorised_values.lib) AS description, authorised_values.imageurl AS imageurl, hideinopac, 1 as 'iscat' FROM itemtypes @@ -110,7 +110,7 @@ sub GetItemTypesCategorized { WHERE searchcategory > '' and hideinopac=1 UNION SELECT DISTINCT searchcategory AS `itemtype`, - authorised_values.lib_opac AS description, + COALESCE(authorised_values.lib_opac,authorised_values.lib) AS description, authorised_values.imageurl AS imageurl, hideinopac, 1 as 'iscat' FROM itemtypes -- 2.39.5