From 039141422618e42f298df13a4d739f2e3d92b2a4 Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Sun, 17 Jul 2011 17:38:02 +0000 Subject: add a array to store who was promoted, to pass to template --- lib/CatDap/Controller/admin.pm | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib') diff --git a/lib/CatDap/Controller/admin.pm b/lib/CatDap/Controller/admin.pm index 6c93212..352c3b1 100644 --- a/lib/CatDap/Controller/admin.pm +++ b/lib/CatDap/Controller/admin.pm @@ -163,6 +163,7 @@ sub account_promote : Local { $c->assert_user_roles('Account Admins'); $c->stash( subpages => gensubpages('account') ); my @errors; + my @promoted; if ( defined $c->req->param('gid') and defined $c->req->param('username') ) { my $gid = $c->req->param('gid'); @@ -206,6 +207,8 @@ sub account_promote : Local { $idpool->replace( uidNumber => $uidnum ); $mesg = $idpool->update; $c->log->info("ERROR IdPool could not be reset to $uidnum: ", $mesg->error) if $mesg->code; + } else { + push @promoted, $uid; } } } @@ -228,6 +231,7 @@ sub account_promote : Local { my @groups = $mesg->entries; $c->stash( groups => \@groups ); $c->stash( errors => \@errors ); + $c->stash( promoted => \@promoted ); } sub account_modify : Local { -- cgit v1.2.1