*/
-Prado::using('System.Web.UI.WebControls.TConditional');
+Prado::using('System.Web.UI.ActiveControls.TActiveRepeater');
Prado::using('Application.Web.Portlets.Portlets');
class Users extends Portlets {
public $web_config;
- public function onInit($param) {
- parent::onInit($param);
+ public function __construct() {
+ parent::__construct();
$this->web_config = $this->getModule('web_config')->getConfig();
- $this->setUsers();
}
public function setUsers() {
if(!$_SESSION['admin']) {
return;
}
+ $this->UsersList->ActiveControl->EnableUpdate = true;
list($action, $user, $value) = explode(';', $param->CallbackParameter, 3);
switch($action) {
case 'newuser':
case 'rmuser': {
if ($user != $_SERVER['PHP_AUTH_USER']) {
$this->getModule('basic_webuser')->removeUser($user);
+ if (array_key_exists('users', $this->web_config) && array_key_exists($user, $this->web_config['users'])) {
+ unset($this->web_config['users'][$user]);
+ }
+ $this->getModule('web_config')->setConfig($this->web_config);
$this->setUsers();
}
break;