From 338141edb54b3b6c8e3f8f1547ad96b2f23015e8 Mon Sep 17 00:00:00 2001 From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Date: Wed, 26 Feb 2020 17:46:49 +0100 Subject: [PATCH] Bug 24736: Disable "Enrollments" link if nobody enrolled to the club yet The link is disabled but it's possible to click and access the page anyway. Test plan: - Create a new club template - Create a new club - Click the Actions > Enrollments link => Without this patch you can access the page => With this patch applied you cannot, and a tooltip explains why (feel free to suggest another wording) - Add a new patron to this club (from /cgi-bin/koha/opac-user.pl#opac-user-clubs) - Notice that the action link is not enabled and click takes you to the list of enrollments Signed-off-by: David Nind <david@davidnind.com> --- koha-tmpl/intranet-tmpl/prog/en/includes/clubs-table.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/clubs-table.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/clubs-table.inc index 06869538aa..e6639c66ee 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/clubs-table.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/clubs-table.inc @@ -77,7 +77,7 @@ </li> [% ELSE %] <li class="disabled"> - <a href="club-enrollments.pl?id=[% c.id | uri %]"> + <a href="#" data-toggle="tooltip" data-placement="left" title="Nobody enrolled for this club yet"> <i class="fa fa-list-ul"></i> Enrollments </a> </li> @@ -108,4 +108,4 @@ </tr> [% END %] </tbody> -</table> <!-- /.clubs-table --> \ No newline at end of file +</table> <!-- /.clubs-table --> -- 2.11.0