From c3d7d5b428ab19fffab3d17b32caa38cd484b34a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Oudot?= Date: Thu, 18 Dec 2014 08:34:23 +0000 Subject: [PATCH] Add active class to show current Manager page (#776) --- lemonldap-ng-manager/example/index.pl | 25 +++++++++++-------- lemonldap-ng-manager/example/notifications.pl | 19 ++++++++------ lemonldap-ng-manager/example/sessions.pl | 19 ++++++++------ .../example/skins/default/top.tpl | 6 ++--- 4 files changed, 39 insertions(+), 30 deletions(-) diff --git a/lemonldap-ng-manager/example/index.pl b/lemonldap-ng-manager/example/index.pl index d6ecd4a72..14cac264b 100755 --- a/lemonldap-ng-manager/example/index.pl +++ b/lemonldap-ng-manager/example/index.pl @@ -35,17 +35,20 @@ my $template = HTML::Template->new( cache => 0, filter => sub { $manager->translate_template(@_) }, ); -$template->param( SCRIPT_NAME => $ENV{SCRIPT_NAME} ); -$template->param( MENU => $manager->menu() ); -$template->param( DIR => "$skin_dir/$skin" ); -$template->param( CFGNUM => $manager->{cfgNum} ); -$template->param( TREE_AUTOCLOSE => $manager->{managerTreeAutoClose} ); -$template->param( TREE_JQUERYCSS => $manager->{managerTreeJqueryCss} ); -$template->param( CSS => $manager->{managerCss} ); -$template->param( CSS_THEME => $manager->{managerCssTheme} ); -$template->param( VERSION => $Lemonldap::NG::Manager::VERSION ); -$template->param( LANG => shift @{ $manager->{lang} } ); -$template->param( PORTAL_URL => $manager->{portal} ); +$template->param( SCRIPT_NAME => $ENV{SCRIPT_NAME} ); +$template->param( MENU => $manager->menu() ); +$template->param( DIR => "$skin_dir/$skin" ); +$template->param( CFGNUM => $manager->{cfgNum} ); +$template->param( TREE_AUTOCLOSE => $manager->{managerTreeAutoClose} ); +$template->param( TREE_JQUERYCSS => $manager->{managerTreeJqueryCss} ); +$template->param( CSS => $manager->{managerCss} ); +$template->param( CSS_THEME => $manager->{managerCssTheme} ); +$template->param( VERSION => $Lemonldap::NG::Manager::VERSION ); +$template->param( LANG => shift @{ $manager->{lang} } ); +$template->param( PORTAL_URL => $manager->{portal} ); +$template->param( LI_CLASS_CONFIGURATION => "active" ); +$template->param( LI_CLASS_SESSION => "" ); +$template->param( LI_CLASS_NOTIFICATION => "" ); print $manager->header('text/html; charset=utf-8'); print $template->output; diff --git a/lemonldap-ng-manager/example/notifications.pl b/lemonldap-ng-manager/example/notifications.pl index ba89a19ad..3a18b5e4e 100755 --- a/lemonldap-ng-manager/example/notifications.pl +++ b/lemonldap-ng-manager/example/notifications.pl @@ -42,14 +42,17 @@ my $template = HTML::Template->new( cache => 0, filter => sub { $cgi->translate_template(@_) }, ); -$template->param( SCRIPT_NAME => $ENV{SCRIPT_NAME} ); -$template->param( TREE => $cgi->tree() ); -$template->param( DIR => "$skin_dir/$skin" ); -$template->param( CSS => $css ); -$template->param( CSS_THEME => $css_theme ); -$template->param( VERSION => $Lemonldap::NG::Manager::VERSION ); -$template->param( LANG => shift @{ $cgi->{lang} } ); -$template->param( PORTAL_URL => $cgi->{portal} ); +$template->param( SCRIPT_NAME => $ENV{SCRIPT_NAME} ); +$template->param( TREE => $cgi->tree() ); +$template->param( DIR => "$skin_dir/$skin" ); +$template->param( CSS => $css ); +$template->param( CSS_THEME => $css_theme ); +$template->param( VERSION => $Lemonldap::NG::Manager::VERSION ); +$template->param( LANG => shift @{ $cgi->{lang} } ); +$template->param( PORTAL_URL => $cgi->{portal} ); +$template->param( LI_CLASS_CONFIGURATION => "" ); +$template->param( LI_CLASS_SESSION => "" ); +$template->param( LI_CLASS_NOTIFICATION => "active" ); print $cgi->header('text/html; charset=utf-8'); print $template->output; diff --git a/lemonldap-ng-manager/example/sessions.pl b/lemonldap-ng-manager/example/sessions.pl index 90eca411e..cd9734472 100755 --- a/lemonldap-ng-manager/example/sessions.pl +++ b/lemonldap-ng-manager/example/sessions.pl @@ -40,14 +40,17 @@ my $template = HTML::Template->new( cache => 0, filter => sub { $cgi->translate_template(@_) }, ); -$template->param( SCRIPT_NAME => $ENV{SCRIPT_NAME} ); -$template->param( TREE => $cgi->tree() ); -$template->param( DIR => "$skin_dir/$skin" ); -$template->param( CSS => $css ); -$template->param( CSS_THEME => $css_theme ); -$template->param( VERSION => $Lemonldap::NG::Manager::VERSION ); -$template->param( LANG => shift @{ $cgi->{lang} } ); -$template->param( PORTAL_URL => $cgi->{portal} ); +$template->param( SCRIPT_NAME => $ENV{SCRIPT_NAME} ); +$template->param( TREE => $cgi->tree() ); +$template->param( DIR => "$skin_dir/$skin" ); +$template->param( CSS => $css ); +$template->param( CSS_THEME => $css_theme ); +$template->param( VERSION => $Lemonldap::NG::Manager::VERSION ); +$template->param( LANG => shift @{ $cgi->{lang} } ); +$template->param( PORTAL_URL => $cgi->{portal} ); +$template->param( LI_CLASS_CONFIGURATION => "" ); +$template->param( LI_CLASS_SESSION => "active" ); +$template->param( LI_CLASS_NOTIFICATION => "" ); print $cgi->header('text/html; charset=utf-8'); print $template->output; diff --git a/lemonldap-ng-manager/example/skins/default/top.tpl b/lemonldap-ng-manager/example/skins/default/top.tpl index c798b4cb8..87be9288b 100644 --- a/lemonldap-ng-manager/example/skins/default/top.tpl +++ b/lemonldap-ng-manager/example/skins/default/top.tpl @@ -13,9 +13,9 @@