[Fusionforge-commits] r7726 - trunk/gforge/www/admin

Julien HEYMAN jheyman at libremir.placard.fr.eu.org
Fri Jun 5 16:36:12 CEST 2009


Author: jheyman
Date: 2009-06-05 16:36:12 +0200 (Fri, 05 Jun 2009)
New Revision: 7726

Modified:
   trunk/gforge/www/admin/useredit.php
   trunk/gforge/www/admin/userlist.php
Log:
Active unix account when we reactive an account

Modified: trunk/gforge/www/admin/useredit.php
===================================================================
--- trunk/gforge/www/admin/useredit.php	2009-06-05 14:34:56 UTC (rev 7725)
+++ trunk/gforge/www/admin/useredit.php	2009-06-05 14:36:12 UTC (rev 7726)
@@ -71,8 +71,12 @@
 	if ($u->getUnixStatus() != 'N') {
 		$u->setUnixStatus($status);
 	} else {
-		// make sure that user doesn't have LDAP entry
-		$u->setUnixStatus('N');
+		if (count($u->getGroups())>0 && $u->isActive()) {
+			$u->setUnixStatus('A');
+		}else{
+			// make sure that user doesn't have LDAP entry
+			$u->setUnixStatus('N');
+		}
 	}
 	
 	if ($u->isError()) {

Modified: trunk/gforge/www/admin/userlist.php
===================================================================
--- trunk/gforge/www/admin/userlist.php	2009-06-05 14:34:56 UTC (rev 7725)
+++ trunk/gforge/www/admin/userlist.php	2009-06-05 14:36:12 UTC (rev 7726)
@@ -48,7 +48,11 @@
 	} else {
 		if(!$u->setStatus($newStatus)) {
 			exit_error('Error',$u->getErrorMessage());
-		}	
+		}
+		if(!$u->setUnixStatus($newStatus)) {
+			exit_error('Error',$u->getErrorMessage());
+		}
+
 	}
 	echo "<h2>" .sprintf(_('User updated to %1$s status'), $statusString)."</h2>";
 }




More information about the Fusionforge-commits mailing list