From 9f321006561668d468ac8d2f4e2e20344272f2f4 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 15 Mar 2011 00:01:23 +0000 Subject: [PATCH] Make account name->id translator able to handle full usernames and groups listed as Group, name --- .../inc/class.importexport_helper_functions.inc.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/importexport/inc/class.importexport_helper_functions.inc.php b/importexport/inc/class.importexport_helper_functions.inc.php index a9cc22577f..112a4c92c9 100755 --- a/importexport/inc/class.importexport_helper_functions.inc.php +++ b/importexport/inc/class.importexport_helper_functions.inc.php @@ -104,6 +104,15 @@ class importexport_helper_functions { } if ( $account_id = $GLOBALS['egw']->accounts->name2id( $account_lid )) { $account_ids[] = $account_id; + continue; + } + if ( $account_id = $GLOBALS['egw']->accounts->name2id( $account_lid, 'account_fullname' )) { + $account_ids[] = $account_id; + continue; + } + // Handle groups listed as Group, + if ( $account_lid[0] == ' ' && $account_id = $GLOBALS['egw']->accounts->name2id( trim($account_lid))) { + $account_ids[] = $account_id; } } return is_array( $_account_lids ) ? $account_ids : implode( ',', (array)$account_ids );