Working on Choice (#595)

This commit is contained in:
Xavier Guimard 2016-07-01 16:59:59 +00:00
parent 6627121200
commit 1577400bf4
2 changed files with 8 additions and 1 deletions

View File

@ -55,6 +55,13 @@ sub checkChoice {
return 1;
}
sub name {
my ( $self, $req, $type ) = @_;
my $n = ref( $req->datas->{enableMods}->[0] );
$n =~ s/^Lemonldap::NG::Portal::(?:(?:UserDB|Auth)::)?//;
return $n;
}
package Lemonldap::NG::Portal::Simple;
# Build authentication loop displayed in template

View File

@ -165,7 +165,7 @@ sub getModule {
)
{
if ( $self->$mod->can('name') ) {
return $self->$mod->can('name');
return $self->$mod->can('name')->($self->mod,$req,$type);
}
else {
my $s = ref( $self->$mod );