summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: af14b5a)
raw | patch | inline | side by side (parent: af14b5a)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 6 Jul 2010 13:58:22 +0000 (13:58 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 6 Jul 2010 13:58:22 +0000 (13:58 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18945 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-core/ihtml/themes/default/framework.tpl | patch | blob | history | |
gosa-core/plugins/admin/users/class_userManagement.inc | patch | blob | history |
diff --git a/gosa-core/ihtml/themes/default/framework.tpl b/gosa-core/ihtml/themes/default/framework.tpl
index fd87bcead395f220d40d65b34ca12a939105fa0f..d6e1886cb085de379a9cbc3cdaba9ba5c1277f14 100644 (file)
{if $hideMenus}
{$contents}
+ {$msg_dialogs}
{else}
diff --git a/gosa-core/plugins/admin/users/class_userManagement.inc b/gosa-core/plugins/admin/users/class_userManagement.inc
index 51dc848bbbdd85bb9290e3e53e01c3f854e663a1..a8aa4369ffe73d675a2c828c9e3f55e9a5ed5c11 100644 (file)
$attrs = $ldap->fetch();
$this->passwordChangeForceable =
in_array('sambaAccount', $attrs['objectClass']) ||
- in_array('posixAccount', $attrs['objectClass']);
+ (in_array('posixAccount', $attrs['objectClass']) && isset($attrs['shadowMax']));
$smarty->assign("passwordChangeForceable" , $this->passwordChangeForceable);
$smarty->assign("enforcePasswordChange" , $this->enforcePasswordChange);
// Update the posix shadow flag...
if($posix){
- $posixAccount = new posixAccount($this->config, $this->dn);
- $posixAccount->is_modified=TRUE;
- $posixAccount->activate_shadowExpire=1;
- $posixAccount->shadowExpire = date('d.m.Y', time() - (1 * 24 * 60 *60));
- $posixAccount->save();
+
+ $current= floor(date("U") /60 /60 /24);
+ $enforceDate = $current - $attrs['shadowMax'][0];
+ $new_attrs = array();
+ $new_attrs['shadowLastChange'] = $enforceDate;
+ $ldap->cd($this->dn);
+ $ldap->modify($new_attrs);
+
+# $posixAccount = new posixAccount($this->config, $this->dn);
+# $posixAccount->is_modified=TRUE;
+# $posixAccount->activate_shadowExpire=1;
+# $posixAccount->shadowExpire = date('d.m.Y', time() - (1 * 24 * 60 *60));
+# $posixAccount->save();
}
// Update the samba kickoff flag...