phpgroupware-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-developers] class.boprojects.inc.php rc2 & cvs


From: Peter Moulding
Subject: [Phpgroupware-developers] class.boprojects.inc.php rc2 & cvs
Date: Thu, 28 Mar 2002 14:59:54 +1100

The Coordinator name was missing from projects so I downloaded the
latest projects updates I could find on CVS. get_account_data() was
missing so at line 135 I replaced:

return $GLOBALS['phpgw']->accounts->get_account_data($account_id);

with:

$this->accounts = CreateObject('phpgwapi.accounts',$account_id);
$this->accounts->read_repository();
$cached_data[$this->accounts->data['account_id']]['account_lid'] =
        $this->accounts->data['account_lid'];
$cached_data[$this->accounts->data['account_id']]['firstname'] =
        $this->accounts->data['firstname'];
$cached_data[$this->accounts->data['account_id']]['lastname'] =
        $this->accounts->data['lastname'];
return $cached_data;

The name was still missing so in class.boprojects.inc.php at line 145 I
added: 

$cached_data[$this->accounts->data['account_id']]['fullname'] =
        
trim($cached_data[$this->accounts->data['account_id']]['firstname']
        . " " . $cached_data[$this->accounts-
>data['account_id']]['lastname']);


If fullname is required in a few places, it could be constructed in
accounts->data so everyone gets the same format full name. I added
trim() to remove spaces if one part of a name is missing.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]