Commit 6bd696aa authored by Xavier Guimard's avatar Xavier Guimard

Trying to display menu (#595)

parent 479a3fac
......@@ -20,7 +20,8 @@ localStorageOptions={ \
notification = 0
checkXSS = 0
portalSkin = bootstrap
templateDir = __pwd__/lemonldap-ng-portal/site/templates
staticPrefix = /
templateDir = __pwd__/lemonldap-ng-portal/example/skin
[handler]
......
......@@ -170,7 +170,7 @@ sub sendHtml {
$htpl = HTML::Template->new(
filehandle => IO::File->new($template),
path => $self->templateDir,
die_on_bad_params => 1,
die_on_bad_params => 0,
die_on_missing_include => 1,
cache => 0,
);
......
......@@ -31,7 +31,7 @@ BEGIN {
sub authInit {
my $self = shift;
my $tmp = $self->SUPER::authInit(@_);
return $tmp unless ( $tmp eq PE_OK );
return $tmp unless ( $tmp == PE_OK );
unless ($initDone) {
eval "use Web::ID";
$self->abort( 'Unable to load Web::ID', $@ ) if ($@);
......
......@@ -40,7 +40,7 @@ sub display {
}
# 1. Good authentication
elsif ( $req->error eq PE_OK ) {
elsif ( $req->error == PE_OK ) {
# 1.1 Image mode
if ( $req->{error} == PE_IMG_OK || $req->{error} == PE_IMG_NOK ) {
......@@ -91,14 +91,7 @@ sub display {
AUTH_ERROR_TYPE => $req->error_type( $req->{menuError} ),
DISPLAY_TAB => $self->conf->{menuDisplayTab},
LOGOUT_URL => $self->conf->{portal} . "?logout=1",
REQUIRE_OLDPASSWORD => $self->conf->{portalRequireOldPassword},
HIDE_OLDPASSWORD =>
0, # Do not hide old password if it is required
DISPLAY_MODULES => $self->conf->{menuDisplayModules},
APPSLIST_MENU => $self->conf->{menuAppslistMenu}
, # For old templates
APPSLIST_DESC => $self->conf->{menuAppslistDesc}
, # For old templates
DISPLAY_MODULES => $self->conf->{menuDisplayModules} || [],
APPSLIST_ORDER => $req->{sessionInfo}->{'appsListOrder'},
PING => $self->conf->{portalPingInterval},
);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment