mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Display client name if contact is not present
This commit is contained in:
parent
02e535b5a1
commit
1a87b05b96
@ -21,7 +21,12 @@ class ClientContactPresenter extends EntityPresenter
|
|||||||
*/
|
*/
|
||||||
public function name()
|
public function name()
|
||||||
{
|
{
|
||||||
return $this->entity->first_name.' '.$this->entity->last_name;
|
$contact_name = $this->entity->first_name.' '.$this->entity->last_name;
|
||||||
|
|
||||||
|
if(strlen($contact_name) > 1)
|
||||||
|
return $contact_name;
|
||||||
|
|
||||||
|
return $this->entity->client->present()->name();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function first_name()
|
public function first_name()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user