diff --git a/addressbook/inc/class.addressbook_bo.inc.php b/addressbook/inc/class.addressbook_bo.inc.php index 49dacb39f9..abda5a7dfd 100755 --- a/addressbook/inc/class.addressbook_bo.inc.php +++ b/addressbook/inc/class.addressbook_bo.inc.php @@ -715,7 +715,7 @@ class addressbook_bo extends addressbook_so { if (isset($data[$name])) { - $data[$name] = egw_time::server2user($data[$name], $date_format); + $data[$name] = egw_time::user2server($data[$name], $date_format); } } return $data; diff --git a/phpgwapi/inc/class.accounts.inc.php b/phpgwapi/inc/class.accounts.inc.php index b580aff013..92fccffb9e 100644 --- a/phpgwapi/inc/class.accounts.inc.php +++ b/phpgwapi/inc/class.accounts.inc.php @@ -1,11 +1,6 @@ complete rewrite in 6/2006 and earlier modifications @@ -31,18 +26,7 @@ * The backend only implements the read, save, delete, name2id and the {set_}members{hips} methods. * The account class implements all other (eg. name2id, id2name) functions on top of these. * - * @link http://www.egroupware.org - * @author Ralf Becker complete rewrite in 6/2006 - * - * Implements the (now depricated) interfaces on the former accounts class written by - * Joseph Engo and Bettina Gille - * Copyright (C) 2000 - 2002 Joseph Engo, Copyright (C) 2003 Joseph Engo, Bettina Gille - * - * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License - * @package api - * @subpackage accounts - * @access public - * @version $Id$ + * read and search return timestamps (account_(created|modified|lastlogin) in server-time! */ class accounts { @@ -455,7 +439,7 @@ class accounts // for current user, add the apps available to him if ($id == $GLOBALS['egw_info']['user']['account_id']) { - foreach($GLOBALS['egw_info']['user']['apps'] as $app => $data) + foreach((array)$GLOBALS['egw_info']['user']['apps'] as $app => $data) { unset($data['table_defs']); // no need for that on the client $account['apps'][$app] = $data; diff --git a/phpgwapi/inc/class.accounts_sql.inc.php b/phpgwapi/inc/class.accounts_sql.inc.php index b8d3d81b92..0175437b34 100644 --- a/phpgwapi/inc/class.accounts_sql.inc.php +++ b/phpgwapi/inc/class.accounts_sql.inc.php @@ -406,8 +406,9 @@ class accounts_sql 'account_email' => $contact['email'], 'person_id' => $contact['id'], 'account_status' => $contact['account_status'], - 'account_created' => $contact['created'], - 'account_modified' => $contact['modified'], + // addressbook_bo::search() returns everything in user-time, need to convert to server-time + 'account_created' => egw_time::user2server($contact['created']), + 'account_modified' => egw_time::user2server($contact['modified']), ); } }