public static function getFromContact(Addressbook_Model_Contact $contact) { $obj = new self($contact->__get('bank_account_number'), $contact->__get('bank_account_name'), $contact->__get('bank_name'), $contact->__get('bank_code')); $obj->setContactId($contact->getId()); $countryCode = $contact->getLetterDrawee()->getPostalAddress()->getCountryCode('DE'); $obj->setCountryCode($countryCode); if (trim($obj->getName()) == '') { $obj->setName($contact->__get('n_fileas')); } return $obj; }