From b4bfd25dc6804c288cd8ea804e0f5844899498fa Mon Sep 17 00:00:00 2001 From: sullrich Date: Fri, 27 Nov 2009 19:02:39 -0500 Subject: Add disabled checkbox. Add code to check for disabled accounts. --- usr/local/www/system_usermanager.php | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) (limited to 'usr') diff --git a/usr/local/www/system_usermanager.php b/usr/local/www/system_usermanager.php index b3403e9..9ff460b 100644 --- a/usr/local/www/system_usermanager.php +++ b/usr/local/www/system_usermanager.php @@ -158,6 +158,7 @@ if (isAllowedPage("system_usermanager")) { $pconfig['uid'] = $a_user[$id]['uid']; $pconfig['authorizedkeys'] = base64_decode($a_user[$id]['authorizedkeys']); $pconfig['priv'] = $a_user[$id]['priv']; + $pconfig['disabled'] = isset($a_user[$id]['disabled']); } } @@ -252,6 +253,11 @@ if (isAllowedPage("system_usermanager")) { $userent['fullname'] = $_POST['fullname']; $userent['expires'] = $_POST['expires']; $userent['authorizedkeys'] = base64_encode($_POST['authorizedkeys']); + + if($_POST['disabled']) + $userent['disabled'] = true; + else + unset($userent['disabled']); if (isset($id) && $a_user[$id]) $a_user[$id] = $userent; @@ -372,6 +378,12 @@ function presubmit() { + + + > + + + /> @@ -601,7 +613,8 @@ function presubmit() { Username Full name - Groups + Disabled + Groups   +   @@ -649,7 +663,7 @@ function presubmit() { endforeach; ?> - + add user @@ -657,7 +671,7 @@ function presubmit() { - +

-- cgit v1.1