Commit 111bfd92 authored by Côme Chilliet's avatar Côme Chilliet
Browse files

Merge branch '6006-expiration-date-in-dashboard-is-02-01-1970' into '1.4-dev'

Resolve "expiration date in dashboard is 02.01.1970"

See merge request fusiondirectory/fd!617
Showing with 7 additions and 7 deletions
+7 -7
...@@ -170,11 +170,11 @@ class dashboardUsers extends simplePlugin ...@@ -170,11 +170,11 @@ class dashboardUsers extends simplePlugin
try { try {
$attributes = [ $attributes = [
'dn' => 'raw', 'dn' => 'raw',
'uid' => 'raw', 'uid' => '*',
'cn' => 'raw', 'cn' => '*',
'telephoneNumber' => 'raw', 'telephoneNumber' => '*',
'manager' => 'raw', 'manager' => '*',
'shadowExpire' => 1, 'shadowExpire' => '*',
]; ];
if (class_available('mailAccount')) { if (class_available('mailAccount')) {
$attributes['mail'] = 'raw'; $attributes['mail'] = 'raw';
...@@ -200,9 +200,9 @@ class dashboardUsers extends simplePlugin ...@@ -200,9 +200,9 @@ class dashboardUsers extends simplePlugin
$next_expired_accounts = []; $next_expired_accounts = [];
foreach ($users as $user) { foreach ($users as $user) {
// Test if account is expired now // Test if account is expired now
if ($user['shadowExpire'] <= $today) { if ($user['shadowExpire'][0] <= $today) {
$expired_accounts[] = static::get_user_infos($user); $expired_accounts[] = static::get_user_infos($user);
} elseif ($user['shadowExpire'] <= $next_expired_date) { } elseif ($user['shadowExpire'][0] <= $next_expired_date) {
$next_expired_accounts[] = static::get_user_infos($user); $next_expired_accounts[] = static::get_user_infos($user);
} }
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment