From: opensides Date: Sat, 27 May 2006 10:20:20 +0000 (+0000) Subject: next part of the expiration code X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=83e41de9937b987ab340828c5eff2c79f827d202;p=gosa.git next part of the expiration code git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3526 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/personal/password/main.inc b/plugins/personal/password/main.inc index 76704c1e5..467a7c6f1 100644 --- a/plugins/personal/password/main.inc +++ b/plugins/personal/password/main.inc @@ -100,7 +100,17 @@ if (!$remove_lock){ } if ($display == ""){ - $display= $smarty->fetch(get_template_path("password.tpl", TRUE)); + if((isset($config->data['MAIN']['ACCOUNTEXPIRED'])) && $config->data['MAIN']['ACCOUNTEXPIRED'] == "0"){ + $display= $smarty->fetch(get_template_path("password.tpl", TRUE)); + }else{ + $expired= ldap_expired_account($config, $ui->dn, $ui->username); + + if($expired == 4){ + $display= $smarty->fetch(get_template_path("nochange.tpl", TRUE)); + }else{ + $display= $smarty->fetch(get_template_path("password.tpl", TRUE)); + } + } } } diff --git a/plugins/personal/password/nochange.tpl b/plugins/personal/password/nochange.tpl new file mode 100644 index 000000000..775bcafe0 --- /dev/null +++ b/plugins/personal/password/nochange.tpl @@ -0,0 +1,11 @@ +
+ {t}Change password not Allowed{/t} +
+ +

+ {t} You are not allowed to change your password at this time{/t} +

+ +
+ + diff --git a/plugins/personal/password/password_expired.tpl b/plugins/personal/password/password_expired.tpl deleted file mode 100644 index 1cefa14f0..000000000 --- a/plugins/personal/password/password_expired.tpl +++ /dev/null @@ -1,48 +0,0 @@ -
- {t}Change password{/t} -
- -

- {t}Your password has expired. To change your personal password use the fields below. The changes take effect immediately. Please memorize the new password, because you wouldn't be able to login without it.{/t} -

- -

- {t}Changing the password affects your authentification on mail, proxy, samba and unix services.{/t} -

- - - - - - - - - - - - - - -
- -
- -

- -   - -

- - - - - -