From a94a9f745556d42e5018695dbaa70a72129cc993 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Wed, 10 Aug 2011 11:44:37 -0400 Subject: [PATCH] Fix for Bug 6696, New category button broken when no categories defined The javascript tablesorter will trigger an error if we try to apply it to a table with no . That error prevented the YUI button script to complete properly, hence the broken button. This patch hides the table in cases where there are no categories and displays an error message instead. Signed-off-by: Katrin Fischer - Deleted all patron categories and checked button was broken - Applied patch and checked again - button shows up - Nice: There is a note now that you have to create categories Signed-off-by: Ian Walls Signed-off-by: Chris Cormack --- koha-tmpl/intranet-tmpl/prog/en/modules/admin/categorie.tt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categorie.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categorie.tt index 6f3489d2e1..b50012f3ac 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categorie.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/categorie.tt @@ -273,6 +273,7 @@ Confirm Deletion of Category [% categorycode |html %][% END %] [% IF ( searchfield ) %] You Searched for [% searchfield %] [% END %] +[% IF ( loop ) %]
 page(s) : @@ -364,6 +365,9 @@ Confirm Deletion of Category [% categorycode |html %][% END %] [% END %] +[% ELSE %] +
No categories have been defined. Create a new category.
+[% END %] [% END %] -- 2.39.5